about summary refs log tree commit diff stats
path: root/apps
Commit message (Collapse)AuthorAgeFilesLines
* 6953Kartik Agaram2020-10-052-0/+180006
|
* 6952 - raytracing: much betterKartik Agaram2020-10-045-2/+330
| | | | | | | | | | | | | | | The image is now visually indistinguishable from the baseline, though the file isn't quite bit-for-bit correct. I found 3 bugs: a) I forgot to normalize the ray. After creating a helper to "automatically" do it for me, it turns out said helper requires manually using. b) I forgot to multiply by t at one place. c) vec3-length was half-written. For the umpteenth time, the bugs were all in the last place I looked. I was worried about spending a lot of time transcribing `main` without any feedback, but that turned out to be perfect.
* 6949 - snapshot of next raytracing milestoneKartik Agaram2020-10-045-70/+372
| | | | | | | | | | | | | Not yet right, but worth a snapshot just because it gives a cool result. Here, try it out: $ ./translate_mu_debug apps/raytracing/3.mu $ ./a.elf > x.ppm Now view x.ppm as an image. In general, this was quite tedious to write. And a still-open question is how to emit the progress bar to stderr. My options are to either duplicate all my print-* functions (already proliferating) or add global variables to Mu.
* 6948 - stress-testing prints of floatsKartik Agaram2020-10-043-0/+151
| | | | Looks good.
* 6946 - print floats somewhat intuitively in hexKartik Agaram2020-10-0413-0/+0
|
* 6943Kartik Agaram2020-10-044-97/+71
| | | | | | | | Move some implementation around for floating-point. I originally thought I wouldn't bother supporting sigils like %xmm0. But it turns out I need them to pass floats into SubX function calls. And it turns out the sigils work fine for free.
* 6942Kartik Agaram2020-10-042-0/+20
|
* 6940Kartik Agaram2020-10-031-10/+10
|
* 6937Kartik Agaram2020-10-031-16/+19
|
* 6935 - raytracing using floatsKartik Agaram2020-10-034-0/+65691
|
* 6934Kartik Agaram2020-10-032-0/+26
|
* 6933Kartik Agaram2020-10-031-10/+11
|
* 6932 - another bug related to floatsKartik Agaram2020-10-032-0/+70
| | | | | | | For most of Mu's history we've selected between primitives based on types just by checking whether a type is a literal or not. Now we've started checking if it's a float as well. However, floats need one additional check: the call site may have an (addr float) that is dereferenced.
* 6931 - support fp registers in variable lookupKartik Agaram2020-10-032-4/+82
|
* 6930Kartik Agaram2020-10-032-4/+2
|
* 6927 - working on a raytracing tutorialKartik Agaram2020-10-036-0/+65619
| | | | https://raytracing.github.io/books/RayTracingInOneWeekend.html
* 6925 - tile: don't try to print escape sequencesKartik Agaram2020-10-013-1/+50
|
* 6922Kartik Agaram2020-10-012-2/+60
|
* 6918Kartik Agaram2020-10-011-0/+0
| | | | Fix CI.
* 6915 - a new family of Mu branch instructionsKartik Agaram2020-09-301-2/+417
| | | | | | The realization of commit 6916 means that we should be using jump-if-addr* after comparing floats. Which is super ugly. Let's create aliases to them called jump-if-float*.
* 6908 - compiling all floating-point operationsKartik Agaram2020-09-3014-41/+725
| | | | | We don't yet support emulating these instructions in `bootstrap`. But generated binaries containing them run natively just fine.
* 6907 - converting to and from floating-pointKartik Agaram2020-09-292-9/+163
| | | | Some bugfixes to the previous commit.
* 6906Kartik Agaram2020-09-292-4/+4
|
* 6905 - first floating-point instruction compilingKartik Agaram2020-09-292-2/+275
| | | | (Though the generated code doesn't work yet.)
* 6904Kartik Agaram2020-09-292-133/+266
| | | | | New fields for primitives to support code-generation for floating-point primitives.
* 6903Kartik Agaram2020-09-292-0/+29
| | | | | | | | | | | | | | | | | | | Make a few tests more self-contained. I'd prefer to just run a function called `setup` first thing on startup and move this portion of convert-mu to it: # initialize global data structures c7 0/subop/copy *Next-block-index 1/imm32 8b/-> *Primitive-type-ids 0/r32/eax 89/<- *Type-id 0/r32/eax # stream-write c7 0/subop/copy *_Program-functions 0/imm32 c7 0/subop/copy *_Program-functions->payload 0/imm32 c7 0/subop/copy *_Program-types 0/imm32 c7 0/subop/copy *_Program-types->payload 0/imm32 c7 0/subop/copy *_Program-signatures 0/imm32 c7 0/subop/copy *_Program-signatures->payload 0/imm32 However, this approach doesn't fix my run_one_test tooling.
* 6902Kartik Agaram2020-09-295-2/+60
|
* 6901Kartik Agaram2020-09-292-8/+32
|
* 6900 - mu.subx: new primitive type 'float'Kartik Agaram2020-09-292-7/+29
| | | | Using it will currently emit incorrect programs.
* 6899Kartik Agaram2020-09-292-2/+2
|
* 6898 - names for floating-point xmm* registersKartik Agaram2020-09-294-0/+0
|
* 6895Kartik Agaram2020-09-281-0/+2
|
* 6891Kartik Agaram2020-09-271-1/+1
|
* 6889Kartik Agaram2020-09-272-4/+60
| | | | | Teach the self-hosted translator about the new /xm32 and /x32 metadata for floating-point registers.
* 6884Kartik Agaram2020-09-271-2/+2
|
* 6883Kartik Agaram2020-09-261-2/+2
|
* 6882Kartik Agaram2020-09-261-8/+0
|
* 6881 - tile: function calls can now be expandedKartik Agaram2020-09-261-7/+20
|
* 6880Kartik Agaram2020-09-261-2/+25
| | | | | We need the state of the stack at the call-site. But rendering is already working surprisingly well.
* 6879Kartik Agaram2020-09-261-14/+18
| | | | Extract a new function.
* 6878 - tile: mock-up for expanding function callsKartik Agaram2020-09-261-8/+16
|
* 6877Kartik Agaram2020-09-262-2/+26
| | | | Track just whether to step inside or not.
* 6876Kartik Agaram2020-09-263-53/+10
| | | | Back to commit 6872.
* 6875Kartik Agaram2020-09-262-1/+29
| | | | | Snapshot. Caching subsidiary stacks is a dead end; they're just the final iteration. We need to render all iterations.
* 6874Kartik Agaram2020-09-261-1/+1
|
* 6873Kartik Agaram2020-09-262-8/+23
| | | | Now saving the subsidiary stack.
* 6872Kartik Agaram2020-09-261-0/+2
| | | | Hackily show function definition.
* 6871Kartik Agaram2020-09-262-2/+3
| | | | Segfault now fixed. Everything seems to be working again.
* 6870Kartik Agaram2020-09-266-65/+103
| | | | | | Emit a stack of not ints but more complex objects containing the int payload. Function calls again segfaulting.
* 6869Kartik Agaram2020-09-261-5/+5
|