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
97 lines
3.0 KiB
C
97 lines
3.0 KiB
C
// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py
|
|
// RUN: %clang_cc1 -triple riscv32 -target-feature +zknh -emit-llvm %s -o - \
|
|
// RUN: -disable-O0-optnone | opt -S -passes=mem2reg \
|
|
// RUN: | FileCheck %s -check-prefix=RV32ZKNH
|
|
|
|
#include <riscv_crypto.h>
|
|
|
|
// RV32ZKNH-LABEL: @sha256sig0(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha256sig0(i32 [[RS1:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha256sig0(uint32_t rs1) {
|
|
return __riscv_sha256sig0(rs1);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha256sig1(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha256sig1(i32 [[RS1:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha256sig1(uint32_t rs1) {
|
|
return __riscv_sha256sig1(rs1);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha256sum0(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha256sum0(i32 [[RS1:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha256sum0(uint32_t rs1) {
|
|
return __riscv_sha256sum0(rs1);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha256sum1(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha256sum1(i32 [[RS1:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha256sum1(uint32_t rs1) {
|
|
return __riscv_sha256sum1(rs1);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sig0h(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sig0h(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sig0h(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sig0h(rs1, rs2);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sig0l(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sig0l(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sig0l(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sig0l(rs1, rs2);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sig1h(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sig1h(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sig1h(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sig1h(rs1, rs2);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sig1l(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sig1l(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sig1l(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sig1l(rs1, rs2);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sum0r(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sum0r(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sum0r(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sum0r(rs1, rs2);
|
|
}
|
|
|
|
// RV32ZKNH-LABEL: @sha512sum1r(
|
|
// RV32ZKNH-NEXT: entry:
|
|
// RV32ZKNH-NEXT: [[TMP0:%.*]] = call i32 @llvm.riscv.sha512sum1r(i32 [[RS1:%.*]], i32 [[RS2:%.*]])
|
|
// RV32ZKNH-NEXT: ret i32 [[TMP0]]
|
|
//
|
|
uint32_t sha512sum1r(uint32_t rs1, uint32_t rs2) {
|
|
return __riscv_sha512sum1r(rs1, rs2);
|
|
}
|