On Friday, 11 September 2015 at 01:35:09 UTC, deadalnix wrote:
On Friday, 11 September 2015 at 01:12:21 UTC, Brandon Ragland wrote:
[...]

Sure. First thing first, try to checkout the project and get it to build and pass the tests (well, some tests will fail, but you should get 0 regressions).

Step 2 would be to modify the test runner to be able to run in 64 or 32 bits. Some tests will have a different result in 32 bits, notably the ones that use the pointer size somewhere. (tests/runner.d)

Step 3 add a m32/m64 flags to SDC. It is using the getopt from phobos and that should be fairly straightforward. (sdc/src/main.d)

Step 4 go through the codegen (libd-llvm) and update it to take the flag into account. (that's the big chunk). There may be some places in the frontend that assume 64 bits pointers, but if so, not many.

Step 5 go through the runtime and do the same. There shouldn't be many here as well, but I'm not sure.

In a first instance, I guess the right move is to target x86 because it is fairly close to x64 so it should work with minimal changes in the runtime.

You can jump in IRC if you want to talk more about the details.

x86 would be easiest to target.

I've checked out the repo, built it so far, and indeed some failures but no big deals.

Currently paging through to get a hold on what's in there. (I'll be the first to admit I don't know squat about the LLVM compiler).

Reply via email to