Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix the representation of C void pointers in LLVM IR
Currently, we have c_void defined to be represented as an empty struct, but LLVM expects C's void* to be represented as i8*. That means we currently generate code in which LLVM doesn't recognize malloc() and free() and can't apply certain optimization that would remove calls to those functions.
- Loading branch information
5902263
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
saw approval from alexcrichton
at dotdash@5902263
5902263
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
merging dotdash/rust/void_type_fixup = 5902263 into auto
5902263
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dotdash/rust/void_type_fixup = 5902263 merged ok, testing candidate = b77a7e7
5902263
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all tests pass:
success: http://buildbot.rust-lang.org/builders/auto-mac-32-opt/builds/3549
success: http://buildbot.rust-lang.org/builders/auto-mac-32-nopt-c/builds/1391
success: http://buildbot.rust-lang.org/builders/auto-mac-32-nopt-t/builds/1395
success: http://buildbot.rust-lang.org/builders/auto-mac-64-opt/builds/3551
success: http://buildbot.rust-lang.org/builders/auto-mac-64-nopt-c/builds/2652
success: http://buildbot.rust-lang.org/builders/auto-mac-64-nopt-t/builds/2657
success: http://buildbot.rust-lang.org/builders/auto-linux-32-opt/builds/3567
success: http://buildbot.rust-lang.org/builders/auto-linux-32-nopt-c/builds/2655
success: http://buildbot.rust-lang.org/builders/auto-linux-32-nopt-t/builds/2661
success: http://buildbot.rust-lang.org/builders/auto-linux-64-opt/builds/3569
success: http://buildbot.rust-lang.org/builders/auto-linux-64-nopt-c/builds/2655
success: http://buildbot.rust-lang.org/builders/auto-linux-64-nopt-t/builds/2660
success: http://buildbot.rust-lang.org/builders/auto-linux-64-x-android/builds/2729
success: http://buildbot.rust-lang.org/builders/auto-win-32-opt/builds/3557
success: http://buildbot.rust-lang.org/builders/auto-win-32-nopt-c/builds/2659
success: http://buildbot.rust-lang.org/builders/auto-win-32-nopt-t/builds/2663
success: http://buildbot.rust-lang.org/builders/auto-bsd-64-opt/builds/3330
5902263
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fast-forwarding master to auto = b77a7e7