about summary refs log tree commit diff stats
path: root/057static_dispatch.cc
Commit message (Collapse)AuthorAgeFilesLines
* bugfix: phase orderingKartik K. Agaram2015-12-151-0/+43
|
* layer 3 of edit/ now workingKartik K. Agaram2015-12-151-0/+21
| | | | | Now I complain before running if a call somewhere doesn't line up with its ingredients, or if no specialization can be made to match it.
* 2610Kartik K. Agaram2015-11-291-5/+5
|
* 2608 - improve errors when static dispatch failsKartik K. Agaram2015-11-291-0/+50
|
* 2607 - resolve some edge cases in static dispatchKartik K. Agaram2015-11-291-6/+70
|
* 2499 - done reorganizing transformsKartik K. Agaram2015-11-281-2/+1
|
* 2487Kartik K. Agaram2015-11-271-4/+17
| | | | | | | | | | | | | | | Ok, now I'm a little happier about our type checking. Type checking lies in three layers: layer 21: checking types, usually at run-time in the VM or just before layer 57: checking type names layer 59: checking type names It's taken me the process of writing this commit to convince myself that all three layers check mappings for literal values in a consistent manner. Layer 21 uses sizes, and layers 57/59 have whitelists, but either way the goal is that number != character != boolean unless mediated through a literal.
* 2483 - to-text can now handle listsKartik K. Agaram2015-11-271-5/+31
| | | | | 'append' also implicitly calls 'to-text' unless there's a better variant.
* 2482 - better choice between valid variantsKartik K. Agaram2015-11-271-2/+31
| | | | Literal '0' ingredients should map to numbers before addresses.
* 2481Kartik K. Agaram2015-11-271-2/+1
|
* 2472Kartik K. Agaram2015-11-221-2/+0
|
* 2470 - allow overloading primitive operationsKartik K. Agaram2015-11-221-3/+28
| | | | | | | | | This turned out to be surprisingly easy: rather than try to specify the types expected by each operation, just have primitive instructions go through any other variants and only remain unnamed if no variants pass. All I had to do was stop using contains_key() anywhere on Recipe_variants, so that I could use get_or_insert() rather than get().
* 2445 - dispatch between shape-shifting variantsKartik K. Agaram2015-11-151-2/+8
| | | | | Starting to leave debug prints around once again, just in case one of them is worth promoting to the trace..
* 2438 - specialize inside header-less recipesKartik K. Agaram2015-11-141-1/+0
| | | | | | | What was I thinking with 2366? Thanks Caleb Couch. It turned out we couldn't call shape-shifting recipes inside the edit/ or sandbox/ apps.
* 2436Kartik K. Agaram2015-11-141-2/+2
|
* 2435Kartik K. Agaram2015-11-131-2/+2
|
* 2421 - 'generic' => 'shape-shifting'Kartik K. Agaram2015-11-101-1/+1
| | | | More evocative, less jargony.
* 2418 - start raising errors on generic callsKartik K. Agaram2015-11-101-6/+7
|
* 2406Kartik K. Agaram2015-11-081-4/+2
| | | | | One new issue: the traces for all tests are perturbed by the .mu files we choose to load.
* 2397Kartik K. Agaram2015-11-081-1/+3
| | | | | Fix that stray issue with a better phase ordering. Another thing I'm not testing.
* 2394 - clean up outputKartik K. Agaram2015-11-071-1/+0
|
* 2393 - redo 2391Kartik K. Agaram2015-11-071-1/+1
| | | | | | | | | | | Got that idea to work with a special-case for 'new'. Requires parsing new's first ingredient, performing the replacement, and then turning it back into a string. I didn't want to replace NEW with ALLOCATE right here, because then it messes with my invariant that transform should never see a naked ALLOCATE. Layer 11 still not working, but everything else is. Let's clean up before we diagnose the new breakage.
* 2392 - undo 2391Kartik K. Agaram2015-11-071-1/+1
| | | | Yup, type ingredients were taking size 1 by default.
* 2391Kartik K. Agaram2015-11-071-1/+1
| | | | | | | | | | | | | No, my idea was abortive. My new plan was to run no transforms for generic recipes, and instead only run them on concrete specializations as they're created. The trouble with this approach is that new contains a type specification in its ingredient which apparently needed to be transformed into an allocate before specialization. But no, how was that working? How was new computing size based on type ingredients? It might have been wrong all along.
* 2387 - edit/ passing except that final undo layerKartik K. Agaram2015-11-071-0/+2
|
* 2386 - core tests passing againKartik K. Agaram2015-11-071-2/+2
| | | | Layer 1 of edit/ is introducing spurious types, though.
* 2383 - new concern: idempotence of transformsKartik K. Agaram2015-11-061-1/+1
| | | | | I'd not paid any attention to it so far, but I need to do so from now on.
* 2382Kartik K. Agaram2015-11-061-0/+1
| | | | Starting to leave commented out prints again out of desperation.
* 2380 - done loading mu codeKartik K. Agaram2015-11-061-7/+7
| | | | | | | | New assertions still failing during tests. This whole implementation of generic recipes is like an extended spike. I don't have nearly enough tests. Ideally I'd have confidence in generics once layer 59 passed its tests.
* 2379 - further improvements to map operationsKartik K. Agaram2015-11-061-2/+2
| | | | | | | Commands run: $ sed -i 's/\([^. (]*\)\.find(\([^)]*\)) != [^.]*\.end()/contains_key(\1, \2)/g' 0[^0]*cc $ sed -i 's/\([^. (]*\)\.find(\([^)]*\)) == [^.]*\.end()/!contains_key(\1, \2)/g' 0[^0]*cc
* 2377 - stop using operator[] in mapKartik K. Agaram2015-11-061-18/+18
| | | | | | | | | | | | | | | | I'm still seeing all sorts of failures in turning on layer 11 of edit/, so I'm backing away and nailing down every culprit I run into. First up: stop accidentally inserting empty objects into maps during lookups. Commands run: $ sed -i 's/\(Recipe_ordinal\|Recipe\|Type_ordinal\|Type\|Memory\)\[\([^]]*\)\] = \(.*\);/put(\1, \2, \3);/' 0[1-9]* $ vi 075scenario_console.cc # manually fix up Memory[Memory[CONSOLE]] $ sed -i 's/\(Memory\)\[\([^]]*\)\]/get_or_insert(\1, \2)/' 0[1-9]* $ sed -i 's/\(Recipe_ordinal\|Type_ordinal\)\[\([^]]*\)\]/get(\1, \2)/' 0[1-9]* $ sed -i 's/\(Recipe\|Type\)\[\([^]]*\)\]/get(\1, \2)/' 0[1-9]* Now mu dies pretty quickly because of all the places I try to lookup a missing value.
* 2366 - disallow static dispatch inside header-less recipesKartik K. Agaram2015-11-051-0/+1
| | | | | Not only can such recipes not have variants, their bodies too will be oblivious to multiple variants or generics.
* 2361Kartik K. Agaram2015-11-041-1/+2
|
* 2358 - starting to tackle the phase ordering problemKartik K. Agaram2015-11-041-2/+2
| | | | | | | A new externality is starting to make its presence felt. Until I sort this out it's going to be hard to finish making duplex-list generic.
* 2350Kartik K. Agaram2015-11-041-1/+7
| | | | Now it's not just tests that define recipe variants.
* 2342 - generalize generic recipesKartik K. Agaram2015-11-011-1/+1
| | | | | Support for type ingredients anywhere. I've been working on this since commit 2331.
* 2336Kartik K. Agaram2015-10-311-8/+18
| | | | Minor tweak: track all recipe variants.
* 2334Kartik K. Agaram2015-10-311-2/+2
|
* 2331 - generic recipe: first passing testKartik K. Agaram2015-10-311-0/+2
|
* 2323 - static dispatch!Kartik K. Agaram2015-10-291-0/+164