Skip to content

Commit f878f75

Browse files
committed
Move lower intrinsics before FP constant emission, in case
intrinsic lowering ever introduces constants. Rename local symbols before printing function bodies, fixing 255.vortex with the CBE!!! llvm-svn: 18534
1 parent fa171f1 commit f878f75

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

llvm/lib/Target/CBackend/Writer.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,15 @@ namespace {
8585
bool runOnFunction(Function &F) {
8686
LI = &getAnalysis<LoopInfo>();
8787

88+
// Get rid of intrinsics we can't handle.
89+
lowerIntrinsics(F);
90+
8891
// Output all floating point constants that cannot be printed accurately.
8992
printFloatingPointConstants(F);
90-
91-
lowerIntrinsics(F);
93+
94+
// Ensure that no local symbols conflict with global symbols.
95+
F.renameLocalSymbols();
96+
9297
printFunction(F);
9398
FPConstantMap.clear();
9499
return false;

0 commit comments

Comments
 (0)