seanjensengrey / unladen-swallow

Automatically exported from code.google.com/p/unladen-swallow
Other
0 stars 0 forks source link

Make LLVM 2.7 enough for Python #131

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
We need LLVM 2.7 to have enough features that CPython can just depend on 
it, rather than needing an in-tree copy that we can fix. To accomplish that, we 
need to:

* Fix OProfile line numbers
* Enable unreachable-based optimizations. 
(http://nondot.org/sabre/LLVMNotes/BuiltinUnreachable.txt)
* Make LLVM shared objects work.
* Make far calls work on PPC and ARM.
* Eliminate static constructors.

Original issue reported on code.google.com by jyass...@gmail.com on 27 Jan 2010 at 7:25

GoogleCodeExporter commented 9 years ago

Original comment by collinw on 27 Jan 2010 at 7:26

GoogleCodeExporter commented 9 years ago
As far as I know, LLVM currently doesn't support fat/universal bitcode modules 
and 
archives. Wouldn't this be necessary as well, in order to support standard Mac 
OS X 
build practices?

Original comment by danchr on 27 Jan 2010 at 8:14

GoogleCodeExporter commented 9 years ago
Wow, you're right, I'd never thought about that.  Bitcode is and isn't target
independent at the same time, because in C, you have to know things like the 
target
ABI in order to lower things correctly, so the bitcode file that clang makes 
isn't
target independent.  :(

Perhaps we could prefix the bitcode file with the target triple and distribute
multiple bitcode files on OS X?

Original comment by reid.kle...@gmail.com on 27 Jan 2010 at 9:26

GoogleCodeExporter commented 9 years ago
danchr: Good point about fat bitcode. (C-derived bitcode is completely target-
dependent because of types like size_t.) I think I'm going to plan to work 
around that 
missing feature instead of implement it though. Reid's suggestion should work 
for us.

Original comment by jyass...@gmail.com on 29 Jan 2010 at 12:07

GoogleCodeExporter commented 9 years ago
I can understand why you don't need the extra work :-) I figured it was worth 
the try to 
lobby for it, as it's a feature I occasionally miss myself. Oh well, you can't 
have it all, I 
guess…

Original comment by danchr on 30 Jan 2010 at 12:25

GoogleCodeExporter commented 9 years ago
2 more things:
1. LLVM needs to be installable and pass its tests on Win32 and Win64. 
Unfortunately, 
I don't have either kind of Windows box, so I can't even test that. I'm looking 
for a 
volunteer around Feb 27, when LLVM 2.7 pre-release 1 comes out. 
(http://lists.cs.uiuc.edu/pipermail/llvmdev/2010-January/029020.html) Of 
course, 
doing a dry run before then would be helpful too.

2. I'd like LLVM to run cleanly under memcheck and Thread Sanitizer 
(http://code.google.com/p/data-race-test/wiki/ThreadSanitizer). I believe it 
already 
does a good job with memcheck, but I'll double-check.

Original comment by jyass...@gmail.com on 1 Feb 2010 at 7:31

GoogleCodeExporter commented 9 years ago
OProfile line numbers worked all along; I just forgot about the -g flag we 
needed to 
pass to Python to enable them. See issue 63 and 
http://code.google.com/p/unladen-
swallow/wiki/UsingOProfile.

Original comment by jyass...@gmail.com on 1 Feb 2010 at 11:53

GoogleCodeExporter commented 9 years ago
This is done, right? What was the final count on things we got in vs things we 
missed?

Original comment by collinw on 22 Mar 2010 at 8:31