Skip to content

Commit 117cf3e

Browse files
committed
Fix for libgccjit 12
1 parent 11f4f16 commit 117cf3e

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/context.rs

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ use rustc_target::spec::{HasTargetSpec, HasWasmCAbiOpt, Target, TlsModel, WasmCA
2525
use crate::callee::get_fn;
2626
use crate::common::SignType;
2727

28+
#[cfg_attr(not(feature = "master"), allow(dead_code))]
2829
pub struct CodegenCx<'gcc, 'tcx> {
2930
pub codegen_unit: &'tcx CodegenUnit<'tcx>,
3031
pub context: &'gcc Context<'gcc>,

src/intrinsic/llvm.rs

+2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ use rustc_codegen_ssa::traits::BuilderMethods;
77
use crate::builder::Builder;
88
use crate::context::CodegenCx;
99

10+
#[cfg_attr(not(feature = "master"), allow(unused_variables))]
1011
pub fn adjust_function<'gcc>(
1112
context: &'gcc Context<'gcc>,
1213
func_name: &str,
@@ -16,6 +17,7 @@ pub fn adjust_function<'gcc>(
1617
// FIXME: we should not need this hack: this is required because both _mm_fcmadd_sch
1718
// and _mm_mask3_fcmadd_round_sch calls llvm.x86.avx512fp16.mask.vfcmadd.csh and we
1819
// seem to need to map this one LLVM intrinsic to 2 different GCC builtins.
20+
#[cfg(feature = "master")]
1921
match func_name {
2022
"__builtin_ia32_vfcmaddcsh_mask3_round" => {
2123
if format!("{:?}", args[3]).ends_with("255") {

0 commit comments

Comments
 (0)