Commit 7d59513d by John Porto

Subzero. ARM32. Enables obj output.

This CL implements two little pieces of the lowering that are needed for --filetype=obj support in arm. With this change, spec2k builds and verifies with --filetype=obj BUG= https://bugs.chromium.org/p/nativeclient/issues/detail?id=4076 R=kschimpf@google.com, stichnot@chromium.org Review URL: https://codereview.chromium.org/1651603003 .
parent 4a659477
......@@ -478,7 +478,7 @@ endif
ifeq ($(TARGET),arm32)
TARGETFLAG=arm32
SETUP=SetupGccArmOpt
SPEC := -O2 --filetype=asm
SPEC := -O2 --filetype=obj
endif
SPECFLAGS :=
SPECBUILDONLY := false
......
......@@ -6437,9 +6437,11 @@ void TargetDataARM32::lowerConstants() {
if (Ctx->getFlags().getDisableTranslation())
return;
switch (Ctx->getFlags().getOutFileType()) {
case FT_Elf:
UnimplementedError(Ctx->getFlags());
break;
case FT_Elf: {
ELFObjectWriter *Writer = Ctx->getObjectWriter();
Writer->writeConstantPool<ConstantFloat>(IceType_f32);
Writer->writeConstantPool<ConstantDouble>(IceType_f64);
} break;
case FT_Asm:
case FT_Iasm: {
OstreamLocker _(Ctx);
......@@ -6455,7 +6457,9 @@ void TargetDataARM32::lowerJumpTables() {
return;
switch (Ctx->getFlags().getOutFileType()) {
case FT_Elf:
UnimplementedError(Ctx->getFlags());
if (!Ctx->getJumpTables().empty()) {
llvm::report_fatal_error("ARM32 does not support jump tables yet.");
}
break;
case FT_Asm:
// Already emitted from Cfg
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment