diff options
author | Fangrui Song <i@maskray.me> | 2024-06-12 16:42:58 -0700 |
---|---|---|
committer | Fangrui Song <i@maskray.me> | 2024-06-12 16:42:58 -0700 |
commit | ca91538c9c6f5328f398ac849dcc4230824b007e (patch) | |
tree | b7c1dac8c190c6f5b654ebcd7c4d7f44763d840e /clang/tools | |
parent | e80c59556d2d71cc2d0dcb2bd712c36cc4043025 (diff) | |
download | llvm-ca91538c9c6f5328f398ac849dcc4230824b007e.zip llvm-ca91538c9c6f5328f398ac849dcc4230824b007e.tar.gz llvm-ca91538c9c6f5328f398ac849dcc4230824b007e.tar.bz2 |
[MC] Move AllowTemporaryLabels setting to MCContext::MCContext
Also delete `AllowTemporaryLabels = true` from MCContext::reset: when
llc supports -save-temp-labels in the next change, this assignment
should be removed to support -compile-twice.
Diffstat (limited to 'clang/tools')
-rw-r--r-- | clang/tools/driver/cc1as_main.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/tools/driver/cc1as_main.cpp b/clang/tools/driver/cc1as_main.cpp index 4eb753a..ce1e181 100644 --- a/clang/tools/driver/cc1as_main.cpp +++ b/clang/tools/driver/cc1as_main.cpp @@ -429,6 +429,7 @@ static bool ExecuteAssemblerImpl(AssemblerInvocation &Opts, MCOptions.MCRelaxAll = Opts.RelaxAll; MCOptions.EmitDwarfUnwind = Opts.EmitDwarfUnwind; MCOptions.EmitCompactUnwindNonCanonical = Opts.EmitCompactUnwindNonCanonical; + MCOptions.MCSaveTempLabels = Opts.SaveTemporaryLabels; MCOptions.X86RelaxRelocations = Opts.RelaxELFRelocations; MCOptions.CompressDebugSections = Opts.CompressDebugSections; MCOptions.AsSecureLogFile = Opts.AsSecureLogFile; @@ -483,8 +484,6 @@ static bool ExecuteAssemblerImpl(AssemblerInvocation &Opts, MOFI->setDarwinTargetVariantSDKVersion(Opts.DarwinTargetVariantSDKVersion); Ctx.setObjectFileInfo(MOFI.get()); - if (Opts.SaveTemporaryLabels) - Ctx.setAllowTemporaryLabels(false); if (Opts.GenDwarfForAssembly) Ctx.setGenDwarfForAssembly(true); if (!Opts.DwarfDebugFlags.empty()) |