<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [AArch64, Kryo] Assertion on atomic i128 load"
   href="https://bugs.llvm.org/show_bug.cgi?id=33491">33491</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[AArch64, Kryo] Assertion on atomic i128 load
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>GlobalISel
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>pirama@google.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The following IR causes llc to fail an assertion in 
TargetSchedModel::computeOperandLatency().  The same passes if CPU is set to
cortex-a73.

; ModuleID = 'bugpoint-reduced-simplified.bc'
source_filename = "bugpoint-output-226530e.bc"
target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"
target triple = "aarch64--linux-android"

$foo = comdat any

; Function Attrs: alwaysinline nounwind sspstrong uwtable
define hidden void @foo() #0 comdat align 2 {
entry:
  %0 = load atomic i128, i128* undef monotonic, align 16
  ret void
}

attributes #0 = { alwaysinline nounwind sspstrong uwtable
"correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false"
"less-precise-fpmad"="false" "no-frame-pointer-elim"="true"
"no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false"
"no-jump-tables"="false" "no-nans-fp-math"="false"
"no-signed-zeros-fp-math"="false" "no-trapping-math"="false"
"stack-protector-buffer-size"="8" "target-cpu"="kryo"
"target-features"="+crc,+crypto,+neon" "unsafe-fp-math"="false"
"use-soft-float"="false" }

!llvm.ident = !{!0}

!0 = !{!"Android clang version 5.0.0  (based on LLVM 5.0.0svn)"}


Assertion:
=================
DefIdx 1 exceeds machine model writes for %vreg0<def>, %vreg1<def> = LDXPX
%vreg2<undef>; mem:Volatile LD16[undef] GPR64:%vreg0,%vreg1 GPR64sp:%vreg2
 (Try with MCSchedModel.CompleteModel set to false)incomplete machine model
UNREACHABLE executed at
/ssd1/pirama/llvm-upstream/llvm/lib/CodeGen/TargetSchedule.cpp:249!
#0 0x0000000001d7638a llvm::sys::PrintStackTrace(llvm::raw_ostream&)
(bin/llc+0x1d7638a)
#1 0x0000000001d7443e llvm::sys::RunSignalHandlers() (bin/llc+0x1d7443e)
#2 0x0000000001d745a2 SignalHandler(int) (bin/llc+0x1d745a2)
#3 0x00007ff722295330 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x10330)
#4 0x00007ff72108dc37 gsignal
/build/eglibc-MjiXCM/eglibc-2.19/signal/../nptl/sysdeps/unix/sysv/linux/raise.c:56:0
#5 0x00007ff721091028 abort
/build/eglibc-MjiXCM/eglibc-2.19/stdlib/abort.c:91:0
#6 0x0000000001d261a5 (bin/llc+0x1d261a5)
#7 0x000000000175efe3
llvm::TargetSchedModel::computeOperandLatency(llvm::MachineInstr const*,
unsigned int, llvm::MachineInstr const*, unsigned int) const
(bin/llc+0x175efe3)
#8 0x00000000016f9344 llvm::ScheduleDAGInstrs::addVRegDefDeps(llvm::SUnit*,
unsigned int) (bin/llc+0x16f9344)
#9 0x00000000016fdd31
llvm::ScheduleDAGInstrs::buildSchedGraph(llvm::AAResults*,
llvm::RegPressureTracker*, llvm::PressureDiffs*, llvm::LiveIntervals*, bool)
(bin/llc+0x16fdd31)
#10 0x0000000001648e46 llvm::ScheduleDAGMILive::schedule() (bin/llc+0x1648e46)
#11 0x00000000016451de (anonymous
namespace)::MachineSchedulerBase::scheduleRegions(llvm::ScheduleDAGInstrs&,
bool) [clone .isra.548] (bin/llc+0x16451de)
#12 0x0000000001647d01 (anonymous
namespace)::MachineScheduler::runOnMachineFunction(llvm::MachineFunction&)
(bin/llc+0x1647d01)
#13 0x00000000015dffc5
llvm::MachineFunctionPass::runOnFunction(llvm::Function&) (bin/llc+0x15dffc5)
#14 0x00000000018a2a43 llvm::FPPassManager::runOnFunction(llvm::Function&)
(bin/llc+0x18a2a43)
#15 0x00000000018a2aec llvm::FPPassManager::runOnModule(llvm::Module&)
(bin/llc+0x18a2aec)
#16 0x00000000018a385f llvm::legacy::PassManagerImpl::run(llvm::Module&)
(bin/llc+0x18a385f)
#17 0x0000000000834947 compileModule(char**, llvm::LLVMContext&)
(bin/llc+0x834947)
#18 0x00000000007d1aec main (bin/llc+0x7d1aec)
#19 0x00007ff721078f45 __libc_start_main
/build/eglibc-MjiXCM/eglibc-2.19/csu/libc-start.c:321:0
#20 0x00000000008296aa _start (bin/llc+0x8296aa)
Stack dump:
0.      Program arguments: bin/llc i128-load.ll 
1.      Running pass 'Function Pass Manager' on module 'i128-load.ll'.
2.      Running pass 'Machine Instruction Scheduler' on function '@foo'
Aborted (core dumped)</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>