Files
TheRock/compiler/amd-llvm/flang/test/Evaluate/fold-dshift.f90
T
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

45 lines
1.6 KiB
Fortran

! RUN: %python %S/test_folding.py %s %flang_fc1
! Test combined shift intrinsics
module consts
integer(1), parameter :: z40_1 = 64_1
end module consts
module dshiftltest
use consts
logical, parameter :: test_lzzz = dshiftl(0, 0, 0) .EQ. 0
logical, parameter :: test_lzzn = dshiftl(0, 0, 12) .EQ. 0
logical, parameter :: test_lnzn = dshiftl(36_1, 0_1, 5) .EQ. -128_2
logical, parameter :: test_lznn = dshiftl(0, 33, 12) .EQ. 0
logical, parameter :: test_l0 = dshiftl(3, 4, 0) .EQ. 3
logical, parameter :: test_l32 = dshiftl(3, 4, 32) .EQ. 4
logical, parameter :: test_l1 = dshiftl(9, 7, 1) .EQ. 18
logical, parameter :: test_l2 = dshiftl(15_1, z40_1, 2) .EQ. 61
logical, parameter :: test_le1 = dshiftl(64_1, 4_1, 7) .EQ. 2
logical, parameter :: test_nb = dshiftl(15_1, Z'40', 2) .EQ. 61
logical, parameter :: test_nbo = dshiftl(15_1, Z'F40', 2) .EQ. 61
end module dshiftltest
module dshiftrtest
use consts
logical, parameter :: test_rzzz = dshiftr(0, 0, 0) .EQ. 0
logical, parameter :: test_rzzn = dshiftr(0, 0, 12) .EQ. 0
logical, parameter :: test_rnzn = dshiftr(36_1, 0_1, 5) .EQ. 32_1
logical, parameter :: test_rznn = dshiftr(0, 33, 12) .EQ. 0
logical, parameter :: test_r0 = dshiftr(3, 4, 0) .EQ. 4
logical, parameter :: test_r32 = dshiftr(3, 4, 32) .EQ. 3
logical, parameter :: test_r1 = dshiftr(4, 17, 1) .EQ. 8
logical, parameter :: test_r2 = dshiftr(15_1, z40_1, 2) .EQ. -48_1
logical, parameter :: test_re1 = dshiftr(64_1, 4_1, 7) .EQ. -128_2
logical, parameter :: test_nb = dshiftr(15_1, Z'40', 2) .EQ. -48_1
logical, parameter :: test_nbo = dshiftr(15_1, Z'F40', 2) .EQ. -48_1
end module dshiftrtest