Lines Matching refs:LLVMConstInt
100 ctx->i8_0 = LLVMConstInt(ctx->i8, 0, false); in ac_llvm_context_init()
101 ctx->i8_1 = LLVMConstInt(ctx->i8, 1, false); in ac_llvm_context_init()
102 ctx->i16_0 = LLVMConstInt(ctx->i16, 0, false); in ac_llvm_context_init()
103 ctx->i16_1 = LLVMConstInt(ctx->i16, 1, false); in ac_llvm_context_init()
104 ctx->i32_0 = LLVMConstInt(ctx->i32, 0, false); in ac_llvm_context_init()
105 ctx->i32_1 = LLVMConstInt(ctx->i32, 1, false); in ac_llvm_context_init()
106 ctx->i64_0 = LLVMConstInt(ctx->i64, 0, false); in ac_llvm_context_init()
107 ctx->i64_1 = LLVMConstInt(ctx->i64, 1, false); in ac_llvm_context_init()
108 ctx->i128_0 = LLVMConstInt(ctx->i128, 0, false); in ac_llvm_context_init()
109 ctx->i128_1 = LLVMConstInt(ctx->i128, 1, false); in ac_llvm_context_init()
117 ctx->i1false = LLVMConstInt(ctx->i1, 0, false); in ac_llvm_context_init()
118 ctx->i1true = LLVMConstInt(ctx->i1, 1, false); in ac_llvm_context_init()
152 return LLVMBuildExtractElement(ac->builder, value, LLVMConstInt(ac->i32, index, false), ""); in ac_llvm_extract_elem()
490 LLVMValueRef args[3] = {value, ctx->i32_0, LLVMConstInt(ctx->i32, LLVMIntNE, 0)}; in ac_build_ballot()
516 LLVMConstInt(ctx->i32, LLVMIntNE, 0), in ac_get_i1_sgpr_mask()
534 return LLVMBuildICmp(ctx->builder, LLVMIntNE, vote_set, LLVMConstInt(ctx->iN_wavemask, 0, 0), in ac_build_vote_any()
545 LLVMBuildICmp(ctx->builder, LLVMIntEQ, vote_set, LLVMConstInt(ctx->iN_wavemask, 0, 0), ""); in ac_build_vote_eq()
564 LLVMValueRef index = LLVMConstInt(ctx->i32, i - component, false); in ac_build_varying_gather_values()
592 LLVMValueRef index = LLVMConstInt(ctx->i32, i, false); in ac_build_gather_values_extended()
724 num = LLVMBuildLShr(builder, num, LLVMConstInt(ctx->i64, 32, 0), ""); in ac_build_fast_udiv()
742 num = LLVMBuildLShr(builder, num, LLVMConstInt(ctx->i64, 32, 0), ""); in ac_build_fast_udiv_nuw()
756 num = LLVMBuildLShr(builder, num, LLVMConstInt(ctx->i64, 32, 0), ""); in ac_build_fast_udiv_u31_d_not_one()
1131 args[idx++] = LLVMConstInt(ctx->i32, cache_policy, 0); in ac_build_buffer_store_common()
1166 v[i] = LLVMBuildExtractElement(ctx->builder, vdata, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_buffer_store_dword()
1184 offset = LLVMBuildAdd(ctx->builder, offset, LLVMConstInt(ctx->i32, inst_offset, 0), ""); in ac_build_buffer_store_dword()
1196 LLVMValueRef immoffset = LLVMConstInt(ctx->i32, inst_offset, 0); in ac_build_buffer_store_dword()
1216 args[idx++] = LLVMConstInt(ctx->i32, get_load_cache_policy(ctx, cache_policy), 0); in ac_build_buffer_load_common()
1244 LLVMValueRef offset = LLVMConstInt(ctx->i32, inst_offset, 0); in ac_build_buffer_load()
1258 offset = LLVMBuildAdd(ctx->builder, offset, LLVMConstInt(ctx->i32, 4, 0), ""); in ac_build_buffer_load()
1263 LLVMConstInt(ctx->i32, get_load_cache_policy(ctx, cache_policy), 0), in ac_build_buffer_load()
1340 args[idx++] = LLVMConstInt(ctx->i32, ac_get_tbuffer_format(ctx->chip_class, dfmt, nfmt), 0); in ac_build_tbuffer_load()
1341 args[idx++] = LLVMConstInt(ctx->i32, get_load_cache_policy(ctx, cache_policy), 0); in ac_build_tbuffer_load()
1399 LLVMBuildAnd(ctx->builder, src, LLVMConstInt(ctx->i32, (1 << mant_bits) - 1, false), ""); in ac_ufN_to_float()
1406 shifted = LLVMBuildShl(ctx->builder, src, LLVMConstInt(ctx->i32, normal_shift, false), ""); in ac_ufN_to_float()
1408 LLVMBuildAdd(ctx->builder, shifted, LLVMConstInt(ctx->i32, bias_shift << 23, false), ""); in ac_ufN_to_float()
1412 naninf = LLVMBuildOr(ctx->builder, normal, LLVMConstInt(ctx->i32, 0xff << 23, false), ""); in ac_ufN_to_float()
1425 tmp = LLVMBuildSub(ctx->builder, ctlz, LLVMConstInt(ctx->i32, 8, false), ""); in ac_ufN_to_float()
1429 tmp = LLVMBuildSub(ctx->builder, LLVMConstInt(ctx->i32, denormal_exp, false), ctlz, ""); in ac_ufN_to_float()
1430 tmp = LLVMBuildShl(ctx->builder, tmp, LLVMConstInt(ctx->i32, 23, false), ""); in ac_ufN_to_float()
1437 LLVMConstInt(ctx->i32, ((1ULL << exp_bits) - 1) << mant_bits, false), ""); in ac_ufN_to_float()
1441 LLVMConstInt(ctx->i32, 1ULL << mant_bits, false), ""); in ac_ufN_to_float()
1502 LLVMBuildAdd(ctx->builder, soffset, LLVMConstInt(ctx->i32, i << load_log_size, false), ""); in ac_build_opencoded_load_format()
1524 tmp = LLVMBuildShl(ctx->builder, tmp, LLVMConstInt(dst_type, 8 * i, false), ""); in ac_build_opencoded_load_format()
1540 tmp = LLVMConstInt(ctx->i32, i, false); in ac_build_opencoded_load_format()
1554 tmp = LLVMConstInt(loaded_type, dst_bits * (i - 1), false); in ac_build_opencoded_load_format()
1571 LLVMValueRef i32_2047 = LLVMConstInt(ctx->i32, 2047, false); in ac_build_opencoded_load_format()
1573 tmp = LLVMBuildLShr(ctx->builder, data, LLVMConstInt(ctx->i32, 11, false), ""); in ac_build_opencoded_load_format()
1575 LLVMValueRef b = LLVMBuildLShr(ctx->builder, data, LLVMConstInt(ctx->i32, 22, false), ""); in ac_build_opencoded_load_format()
1590 tmp = LLVMBuildLShr(ctx->builder, data, LLVMConstInt(ctx->i32, 10, false), ""); in ac_build_opencoded_load_format()
1592 tmp = LLVMBuildLShr(ctx->builder, data, LLVMConstInt(ctx->i32, 20, false), ""); in ac_build_opencoded_load_format()
1594 tmp = LLVMBuildLShr(ctx->builder, data, LLVMConstInt(ctx->i32, 30, false), ""); in ac_build_opencoded_load_format()
1692 args[idx++] = LLVMConstInt(ctx->i32, ac_get_tbuffer_format(ctx->chip_class, dfmt, nfmt), 0); in ac_build_tbuffer_store()
1693 args[idx++] = LLVMConstInt(ctx->i32, cache_policy, 0); in ac_build_tbuffer_store()
1759 md_args[0] = LLVMConstInt(type, lo, false); in ac_set_range_metadata()
1760 md_args[1] = LLVMConstInt(type, hi, false); in ac_set_range_metadata()
1767 return ac_build_mbcnt(ctx, LLVMConstInt(ctx->iN_wavemask, ~0ull, 0)); in ac_get_thread_id()
1836 args[0] = LLVMConstInt(ctx->i32, msg, false); in ac_build_sendmsg()
1848 msb = LLVMBuildSub(ctx->builder, LLVMConstInt(ctx->i32, 31, false), msb, ""); in ac_build_imsb()
1850 LLVMValueRef all_ones = LLVMConstInt(ctx->i32, -1, true); in ac_build_imsb()
1871 highest_bit = LLVMConstInt(ctx->i64, 63, false); in ac_build_umsb()
1877 highest_bit = LLVMConstInt(ctx->i32, 31, false); in ac_build_umsb()
1883 highest_bit = LLVMConstInt(ctx->i16, 15, false); in ac_build_umsb()
1889 highest_bit = LLVMConstInt(ctx->i8, 7, false); in ac_build_umsb()
1916 LLVMConstInt(ctx->i32, -1, true), msb, ""); in ac_build_umsb()
1974 args[0] = LLVMConstInt(ctx->i32, a->target, 0); in ac_build_export()
1975 args[1] = LLVMConstInt(ctx->i32, a->enabled_channels, 0); in ac_build_export()
1980 args[4] = LLVMConstInt(ctx->i1, a->done, 0); in ac_build_export()
1981 args[5] = LLVMConstInt(ctx->i1, a->valid_mask, 0); in ac_build_export()
1989 args[6] = LLVMConstInt(ctx->i1, a->done, 0); in ac_build_export()
1990 args[7] = LLVMConstInt(ctx->i1, a->valid_mask, 0); in ac_build_export()
2180 args[num_args++] = LLVMConstInt(ctx->i32, dmask, false); in ac_build_image_opcode()
2209 args[num_args++] = LLVMConstInt(ctx->i1, a->unorm, false); in ac_build_image_opcode()
2213 args[num_args++] = LLVMConstInt( in ac_build_image_opcode()
2324 samples = LLVMBuildExtractElement(ctx->builder, rsrc, LLVMConstInt(ctx->i32, 3, 0), ""); in ac_build_image_get_sample_count()
2325 samples = LLVMBuildLShr(ctx->builder, samples, LLVMConstInt(ctx->i32, 16, 0), ""); in ac_build_image_get_sample_count()
2326 samples = LLVMBuildAnd(ctx->builder, samples, LLVMConstInt(ctx->i32, 0xf, 0), ""); in ac_build_image_get_sample_count()
2379 LLVMValueRef max_rgb = LLVMConstInt(ctx->i32, bits == 8 ? 127 : bits == 10 ? 511 : 32767, 0); in ac_build_cvt_pk_i16()
2380 LLVMValueRef min_rgb = LLVMConstInt(ctx->i32, bits == 8 ? -128 : bits == 10 ? -512 : -32768, 0); in ac_build_cvt_pk_i16()
2382 LLVMValueRef min_alpha = bits != 10 ? min_rgb : LLVMConstInt(ctx->i32, -2, 0); in ac_build_cvt_pk_i16()
2404 LLVMValueRef max_rgb = LLVMConstInt(ctx->i32, bits == 8 ? 255 : bits == 10 ? 1023 : 65535, 0); in ac_build_cvt_pk_u16()
2405 LLVMValueRef max_alpha = bits != 10 ? max_rgb : LLVMConstInt(ctx->i32, 3, 0); in ac_build_cvt_pk_u16()
2493 LLVMConstInt(ctx->i32, simm16, false), in ac_build_waitcnt()
2568 LLVMValueRef scalar = LLVMConstInt(LLVMGetElementType(type), value, 0); in ac_const_uint_vec()
2576 return LLVMConstInt(type, value, 0); in ac_const_uint_vec()
2632 ctx->builder, pos, LLVMConstInt(ctx->i32, 0x3FF00000, 0), in ac_build_fsign()
2633 LLVMBuildSelect(ctx->builder, neg, LLVMConstInt(ctx->i32, 0xBFF00000, 0), ctx->i32_0, ""), in ac_build_fsign()
2857 LLVMConstInt(ctx->i32, enabled_channels, 0)); in ac_eliminate_duplicated_output()
2975 LLVMConstInt(ctx->i32, V_008DFC_SQ_EXP_PARAM + i, 0)); in ac_optimize_vs_outputs()
2983 LLVMValueRef full_mask = LLVMConstInt(ctx->i64, ~0ull, 0); in ac_init_exec_full_mask()
3065 LLVMConstInt(ctx->i32, -1, 0), lsb, ""); in ac_find_lsb()
3291 masks[i] = LLVMConstInt(ctx->i32, i, false); in ac_trim_vector()
3306 … value = LLVMBuildLShr(ctx->builder, value, LLVMConstInt(LLVMTypeOf(param), rshift, false), ""); in ac_unpack_param()
3310 value = LLVMBuildAnd(ctx->builder, value, LLVMConstInt(LLVMTypeOf(param), mask, false), ""); in ac_unpack_param()
3359 LLVMBuildSelect(ac->builder, tmp, fmask_value, LLVMConstInt(ac->i32, 0x76543210, false), ""); in ac_apply_fmask_to_sample()
3365 LLVMConstInt(LLVMTypeOf(addr[0]), 4, 0), ""); in ac_apply_fmask_to_sample()
3370 addr[sample_chan] = LLVMBuildAnd(ac->builder, final_sample, LLVMConstInt(ac->i32, 0x7, 0), ""); in ac_apply_fmask_to_sample()
3412 src = LLVMBuildExtractElement(ctx->builder, src_vector, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_readlane_common()
3417 LLVMBuildInsertElement(ctx->builder, ret, ret_comp, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_readlane_common()
3530 (LLVMValueRef[]){old, src, LLVMConstInt(ctx->i32, dpp_ctrl, 0), in _ac_build_dpp()
3531 LLVMConstInt(ctx->i32, row_mask, 0), LLVMConstInt(ctx->i32, bank_mask, 0), in _ac_build_dpp()
3532 LLVMConstInt(ctx->i1, bound_ctrl, 0)}, in _ac_build_dpp()
3554 src = LLVMBuildExtractElement(ctx->builder, src_vector, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_dpp()
3555 old = LLVMBuildExtractElement(ctx->builder, old_vector, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_dpp()
3559 LLVMBuildInsertElement(ctx->builder, ret, ret_comp, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_dpp()
3578 LLVMConstInt(ctx->i32, sel, false), in _ac_build_permlane16()
3579 LLVMConstInt(ctx->i32, sel >> 32, false), in _ac_build_permlane16()
3604 src = LLVMBuildExtractElement(ctx->builder, src_vector, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_permlane16()
3607 LLVMBuildInsertElement(ctx->builder, ret, ret_comp, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_permlane16()
3630 (LLVMValueRef[]){src, LLVMConstInt(ctx->i32, mask, 0)}, 2, in _ac_build_ds_swizzle()
3648 src = LLVMBuildExtractElement(ctx->builder, src_vector, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_ds_swizzle()
3651 LLVMBuildInsertElement(ctx->builder, ret, ret_comp, LLVMConstInt(ctx->i32, i, 0), ""); in ac_build_ds_swizzle()
3715 return LLVMConstInt(ctx->i1, 0, 0); in get_reduction_identity()
3717 return LLVMConstInt(ctx->i1, 1, 0); in get_reduction_identity()
3728 return LLVMConstInt(ctx->i8, INT8_MAX, 0); in get_reduction_identity()
3730 return LLVMConstInt(ctx->i8, UINT8_MAX, 0); in get_reduction_identity()
3732 return LLVMConstInt(ctx->i8, INT8_MIN, 0); in get_reduction_identity()
3736 return LLVMConstInt(ctx->i8, -1, 0); in get_reduction_identity()
3755 return LLVMConstInt(ctx->i16, INT16_MAX, 0); in get_reduction_identity()
3757 return LLVMConstInt(ctx->i16, UINT16_MAX, 0); in get_reduction_identity()
3761 return LLVMConstInt(ctx->i16, INT16_MIN, 0); in get_reduction_identity()
3767 return LLVMConstInt(ctx->i16, -1, 0); in get_reduction_identity()
3786 return LLVMConstInt(ctx->i32, INT32_MAX, 0); in get_reduction_identity()
3788 return LLVMConstInt(ctx->i32, UINT32_MAX, 0); in get_reduction_identity()
3792 return LLVMConstInt(ctx->i32, INT32_MIN, 0); in get_reduction_identity()
3798 return LLVMConstInt(ctx->i32, -1, 0); in get_reduction_identity()
3817 return LLVMConstInt(ctx->i64, INT64_MAX, 0); in get_reduction_identity()
3819 return LLVMConstInt(ctx->i64, UINT64_MAX, 0); in get_reduction_identity()
3823 return LLVMConstInt(ctx->i64, INT64_MIN, 0); in get_reduction_identity()
3829 return LLVMConstInt(ctx->i64, -1, 0); in get_reduction_identity()
3908 LLVMBuildICmp(ctx->builder, LLVMIntEQ, tid, LLVMConstInt(ctx->i32, 32, false), ""); in ac_wavefront_shift_right_1()
3911 ac_build_readlane(ctx, src, LLVMConstInt(ctx->i32, 31, false)), in ac_wavefront_shift_right_1()
3917 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 0x1f, false), ""), in ac_wavefront_shift_right_1()
3918 LLVMConstInt(ctx->i32, 0x10, false), ""), in ac_wavefront_shift_right_1()
3923 LLVMBuildICmp(ctx->builder, LLVMIntEQ, tid, LLVMConstInt(ctx->i32, 16, false), ""); in ac_wavefront_shift_right_1()
3937 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 0x7, 0), ""), in ac_wavefront_shift_right_1()
3938 LLVMConstInt(ctx->i32, 0x4, 0), ""); in ac_wavefront_shift_right_1()
3942 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 0xf, 0), ""), in ac_wavefront_shift_right_1()
3943 LLVMConstInt(ctx->i32, 0x8, 0), ""); in ac_wavefront_shift_right_1()
3947 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 0x1f, 0), ""), in ac_wavefront_shift_right_1()
3948 LLVMConstInt(ctx->i32, 0x10, 0), ""); in ac_wavefront_shift_right_1()
3950 tmp2 = ac_build_readlane(ctx, src, LLVMConstInt(ctx->i32, 31, 0)); in ac_wavefront_shift_right_1()
3951 active = LLVMBuildICmp(ctx->builder, LLVMIntEQ, tid, LLVMConstInt(ctx->i32, 32, 0), ""); in ac_wavefront_shift_right_1()
3953 active = LLVMBuildICmp(ctx->builder, LLVMIntEQ, tid, LLVMConstInt(ctx->i32, 0, 0), ""); in ac_wavefront_shift_right_1()
3982 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 2, 0), ""), in ac_build_scan()
3988 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 4, 0), ""), in ac_build_scan()
3994 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 8, 0), ""), in ac_build_scan()
4000 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 16, 0), ""), in ac_build_scan()
4004 tmp = ac_build_readlane(ctx, result, LLVMConstInt(ctx->i32, 31, 0)); in ac_build_scan()
4006 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 32, 0), ""), in ac_build_scan()
4043 LLVMBuildAnd(ctx->builder, tid, LLVMConstInt(ctx->i32, 16, false), ""), in ac_build_scan()
4053 tmp = ac_build_readlane(ctx, result, LLVMConstInt(ctx->i32, 31, false)); in ac_build_scan()
4055 active = LLVMBuildICmp(ctx->builder, LLVMIntUGE, tid, LLVMConstInt(ctx->i32, 32, false), ""); in ac_build_scan()
4166 swap = ac_build_readlane(ctx, result, LLVMConstInt(ctx->i32, 31, false)); in ac_build_reduce()
4170 result = ac_build_readlane(ctx, result, LLVMConstInt(ctx->i32, 63, 0)); in ac_build_reduce()
4176 result = ac_build_readlane(ctx, result, LLVMConstInt(ctx->i32, 32, 0)); in ac_build_reduce()
4194 const LLVMValueRef last_lane = LLVMConstInt(ctx->i32, ctx->wave_size - 1, false); in ac_build_wg_wavescan_top()
4360 index = LLVMBuildMul(ctx->builder, index, LLVMConstInt(ctx->i32, 4, 0), ""); in ac_build_shuffle()
4445 a = LLVMBuildExtractElement(ctx->builder, interp_ij, LLVMConstInt(ctx->i32, i, false), ""); in ac_build_ddxy_interp()
4519 stencil = LLVMBuildShl(ctx->builder, stencil, LLVMConstInt(ctx->i32, 16, 0), ""); in ac_export_mrt_z()
4577 tmp = LLVMBuildShl(builder, prim_cnt, LLVMConstInt(ctx->i32, 12, false), ""); in ac_build_sendmsg_gs_alloc_req()
4614 LLVMConstInt(ctx->i32, 0x700, 0), ""); in ac_pack_edgeflags_for_export()
4615 tmp = LLVMBuildMul(ctx->builder, tmp, LLVMConstInt(ctx->i32, 0x80402u, 0), ""); in ac_pack_edgeflags_for_export()
4616 return LLVMBuildAnd(ctx->builder, tmp, LLVMConstInt(ctx->i32, 0x20080200, 0), ""); in ac_pack_edgeflags_for_export()
4632 LLVMValueRef result = LLVMBuildShl(builder, tmp, LLVMConstInt(ctx->i32, 31, false), ""); in ac_pack_prim_export()
4636 tmp = LLVMBuildShl(builder, prim->index[i], LLVMConstInt(ctx->i32, 10 * i, false), ""); in ac_pack_prim_export()