Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion llvm/lib/Target/BPF/BPFISelLowering.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ BPFTargetLowering::BPFTargetLowering(const TargetMachine &TM,
if (VT == MVT::i32 && !STI.getHasAlu32())
continue;

setOperationAction(ISD::SDIV, VT, Expand);
setOperationAction(ISD::SDIVREM, VT, Expand);
setOperationAction(ISD::UDIVREM, VT, Expand);
setOperationAction(ISD::SREM, VT, Expand);
Expand Down Expand Up @@ -382,7 +383,7 @@ SDValue BPFTargetLowering::LowerCall(TargetLowering::CallLoweringInfo &CLI,
// Pass the current stack frame pointer via BPF::R5
Chain = DAG.getCopyToReg(Chain, CLI.DL, BPF::R5, FramePtr);
}

SDValue InFlag;

// Build a sequence of copy-to-reg nodes chained together with token chain and
Expand Down
1 change: 1 addition & 0 deletions llvm/test/CodeGen/BPF/sdiv_error.ll
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
; XFAIL: *
; RUN: not llc -march=bpf < %s 2> %t1
; RUN: FileCheck %s < %t1
; CHECK: Unsupport signed division
Expand Down