about summary refs log tree commit diff stats
path: root/038scheduler.cc
Commit message (Collapse)AuthorAgeFilesLines
* 1620Kartik K. Agaram2015-06-221-0/+1
| | | | | | | | chessboard finally passing all its tests. What made this hard was that for some reason one of the background routines in the main chessboard test wasn't terminating like it used to. And so it was polluting *later* tests. Just clean up that source of contamination for now. Later we'll think about routine termination.
* 1585Kartik K. Agaram2015-06-171-1/+1
|
* 1518 - still horribly brokenKartik K. Agaram2015-06-011-0/+3
| | | | | | Just figured out why a first keystroke of backspace was sending me out for a spin: run_interactive needs all early exits that don't actually run anything to increment the current_step_index(). FML, this is lousy..
* 1483 - *really* check color screens in scenariosKartik K. Agaram2015-05-271-2/+2
| | | | | | | | | | | | | | | | | Required fixing two levels of bugs: a) The hack in tangle to drop initial comments a '%' directive.. b) ..was masking a bug where run_mu_scenario wasn't robust to initial comments. Mildly concerned that neither of the sub-issues have their own tests, but I'm just removing hacks, and writing tests for that throwaway function like run_mu_scenario seems pointless. Instead I've solved the problem by disallowing comments before '%' directives. I've also taken this opportunity to at least try to document the 'scenarios' and '%' directives at the first layer where they appear.
* 1414 - traces now robust to new recipes/typesKartik K. Agaram2015-05-211-9/+9
|
* 1391 - avoid unsigned integersKartik K. Agaram2015-05-171-26/+26
|
* 1383 - warn on unknown typeKartik K. Agaram2015-05-161-0/+4
| | | | | | | | | | | | | This bit me in the last commit for the first time. Layer 010vm.cc is starting to look weird. It has references to stuff that gets implemented much later, like containers and exclusive containers. Its helpers are getting an increasing amount of logic. And it has no tests. I'm still inclined to think it's useful to have major data structures in one place, even if they aren't used for a bit. But those helpers should perhaps move out somehow or get some tests in the same layer.
* 1364 - trace call-stack when switching routinesKartik K. Agaram2015-05-131-2/+12
| | | | Drop the #$%# 'encapsulated' stack ADT.
* 1363 - rename 'integer' to 'number'Kartik K. Agaram2015-05-131-23/+24
| | | | ..now that we support non-integers.
* 1361Kartik K. Agaram2015-05-121-2/+2
| | | | | This one layer had grown a dependency on a later layer. I could swear I ran all the tests when I fixed the test harness in 1358..
* 1357 - temporarily revert floating-point supportKartik K. Agaram2015-05-121-2/+2
|
* 1356 - snapshot #2: floating point supportKartik K. Agaram2015-05-121-2/+2
| | | | | | | | | | | | | | | I added one test to check that divide can return a float, then hacked at the rippling failures across the entire entire codebase until all tests pass. Now I need to look at the changes I made and see if there's a system to them, identify other places that I missed, and figure out the best way to cover all cases. I also need to show real rather than encoded values in the traces, but I can't use value() inside reagent methods because of the name clash with the member variable. So let's take a snapshot before we attempt any refactoring. This was non-trivial to get right. Even if I convince myself that I've gotten it right, I might back this all out if I can't easily *persuade others* that I've gotten it right.
* 1321 - *finally*, fixed the chessboard sluggishnessKartik K. Agaram2015-05-101-0/+17
|
* 1318 - 1317 actually works nowKartik K. Agaram2015-05-101-7/+38
|
* 1317 - all tests passingKartik K. Agaram2015-05-091-6/+34
| | | | Hacky new way to turn off child threads.
* 1315 - chessboard now working interactivelyKartik K. Agaram2015-05-091-0/+6
| | | | | | | | | | | | | | | | | | | | I tried to bring too much into this commit, and paid the price with some debugging effort. Still havent't tried to enable line buffering, but I'll take a snapshot. Some tests are failing because of the huge hack in the scheduler. For a while I thought there was a bug in termbox because I kept seeing segfaults and valgrind complained about out-of-bounds access. But that was just subsidiary threads trying to print to the screen after I'd returned to console mode. Maybe I should add a test for send-keys-to-channel. Or just use a fake keyboard rather than a channel. And *then* there's the fact that the interaction is molasses slow. Slower than the arc version even though the tests run so much faster. And what's with the long pauses in printing strings to screen?
* 1308Kartik K. Agaram2015-05-081-0/+13
|
* 1301 - back to the chessboardKartik K. Agaram2015-05-071-0/+17
| | | | Still need a nice syntax for managing the routine under test.
* 1299 - stop using [] in any vectorKartik K. Agaram2015-05-071-8/+8
| | | | | | | | | Useful check: $ grep "[^ '\"]\[[^\"]" *.cc \ |perl -pwe 's/\Wargv\[|\WTests\[|\Wframe\[|\WMemory\[|\WName\[|\WSurrounding_space\[|\WRecipe\[|\WType\[|\WRecipe_number\[|\WType_number\[|\WBefore_fragments\[|\WAfter_fragments\[//g' \ |perl -pwe 's/\Wargv\[|\WTests\[|\Wframe\[|\WMemory\[|\WName\[|\WSurrounding_space\[|\WRecipe\[|\WType\[|\WRecipe_number\[|\WType_number\[|\WBefore_fragments\[|\WAfter_fragments\[//g' \ |grep '[^ ]\['
* 1298 - better ingredient/product handlingKartik K. Agaram2015-05-071-13/+12
| | | | | | | | | | | | | | | | | | | All primitives now always write to all their products. If a product is not used that's fine, but if an instruction seems to expect too many products mu will complain. In the process, many primitives can operate on more than two ingredients where it seems intuitive. You can add or divide more than two numbers together, copy or negate multiple corresponding locations, etc. There's one remaining bit of ugliness. Some instructions like get/get-address, index/index-address, wait-for-location, these can unnecessarily load values from memory when they don't need to. Useful vim commands: %s/ingredients\[\([^\]]*\)\]/ingredients.at(\1)/gc %s/products\[\([^\]]*\)\]/products.at(\1)/gc .,$s/\[\(.\)]/.at(\1)/gc
* 1296 - roll back 1295Kartik K. Agaram2015-05-071-31/+3
|
* 1295 - broken snapshotKartik K. Agaram2015-05-071-3/+31
| | | | | I spent a couple of hours debugging this because routine-state only sometimes writes to its product. This is unacceptable. Fix this first.
* 1290Kartik K. Agaram2015-05-061-5/+4
|
* 1276 - make C++ version the defaultKartik K. Agaram2015-05-051-0/+244
I've tried to update the Readme, but there are at least a couple of issues.
n653'>653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743