[PATCH] D35480: [mips] Support `long_call/far/near` attributes passed by front-end
Simon Dardis via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 17 14:14:18 PDT 2017
sdardis added a comment.
Some minor nits. Also, see my question inline.
================
Comment at: lib/Target/Mips/MipsISelLowering.cpp:3156
+ if (!Subtarget.isABICalls() && !IsPIC) {
+ if (auto *N = dyn_cast<ExternalSymbolSDNode>(Callee)) {
+ if (Subtarget.useLongCalls())
----------------
Restore the comment from lines 3156-3157 to an appropriate place.
Question (I haven't looked throughly yet): Can an ExternalSymbolSDNode have the long-call/near-call attribute?
If it can, then this expansion code is missing the portions that check the attributes of the ExternalSymbolSDNode.
================
Comment at: test/CodeGen/Mips/long-call-attr.ll:5
+; RUN: | FileCheck %s
+
+declare void @far() #0
----------------
Also requires testing for mips64.
================
Comment at: test/CodeGen/Mips/long-call-attr.ll:15
+
+; CHECK: lui $1, %hi(far)
+; CHECK-NEXT: addiu $25, $1, %lo(far)
----------------
; CHECK-LABEL: foo: before this.
Repository:
rL LLVM
https://reviews.llvm.org/D35480
More information about the llvm-commits
mailing list