https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128326
Bug ID: 128326
Summary: spaceshipti4 should be implemented for aarch64
Product: gcc
Version: 17.0
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: pinskia at gcc dot gnu.org
Depends on: 116509
Target Milestone: ---
Target: aarch64
Created attachment 66051
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=66051&action=edit
testcase
Related to PR 116509 but this is with spaceship operators instead.
This might need to depend on PR 116509 though.
But anyways llvm produces:
```
cmp x2, x0
sbcs xzr, x3, x1
cset w8, lt
cmp x0, x2
sbcs xzr, x1, x3
csinv w0, w8, wzr, ge
```
For the signed case. The unsigned case should be similar.
Referenced Bugs:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116509
[Bug 116509] 128bit integer compares can be improved