@@ -2958,37 +2958,37 @@ bool AMDGPUAsmParser::ParseDirectiveAMDHSAKernel() {
2958
2958
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2959
2959
KERNEL_CODE_PROPERTY_ENABLE_SGPR_PRIVATE_SEGMENT_BUFFER,
2960
2960
Val, ValRange);
2961
- UserSGPRCount++ ;
2961
+ UserSGPRCount += 4 ;
2962
2962
} else if (ID == " .amdhsa_user_sgpr_dispatch_ptr" ) {
2963
2963
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2964
2964
KERNEL_CODE_PROPERTY_ENABLE_SGPR_DISPATCH_PTR, Val,
2965
2965
ValRange);
2966
- UserSGPRCount++ ;
2966
+ UserSGPRCount += 2 ;
2967
2967
} else if (ID == " .amdhsa_user_sgpr_queue_ptr" ) {
2968
2968
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2969
2969
KERNEL_CODE_PROPERTY_ENABLE_SGPR_QUEUE_PTR, Val,
2970
2970
ValRange);
2971
- UserSGPRCount++ ;
2971
+ UserSGPRCount += 2 ;
2972
2972
} else if (ID == " .amdhsa_user_sgpr_kernarg_segment_ptr" ) {
2973
2973
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2974
2974
KERNEL_CODE_PROPERTY_ENABLE_SGPR_KERNARG_SEGMENT_PTR,
2975
2975
Val, ValRange);
2976
- UserSGPRCount++ ;
2976
+ UserSGPRCount += 2 ;
2977
2977
} else if (ID == " .amdhsa_user_sgpr_dispatch_id" ) {
2978
2978
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2979
2979
KERNEL_CODE_PROPERTY_ENABLE_SGPR_DISPATCH_ID, Val,
2980
2980
ValRange);
2981
- UserSGPRCount++ ;
2981
+ UserSGPRCount += 2 ;
2982
2982
} else if (ID == " .amdhsa_user_sgpr_flat_scratch_init" ) {
2983
2983
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2984
2984
KERNEL_CODE_PROPERTY_ENABLE_SGPR_FLAT_SCRATCH_INIT, Val,
2985
2985
ValRange);
2986
- UserSGPRCount++ ;
2986
+ UserSGPRCount += 2 ;
2987
2987
} else if (ID == " .amdhsa_user_sgpr_private_segment_size" ) {
2988
2988
PARSE_BITS_ENTRY (KD.kernel_code_properties ,
2989
2989
KERNEL_CODE_PROPERTY_ENABLE_SGPR_PRIVATE_SEGMENT_SIZE,
2990
2990
Val, ValRange);
2991
- UserSGPRCount++ ;
2991
+ UserSGPRCount += 1 ;
2992
2992
} else if (ID == " .amdhsa_system_sgpr_private_segment_wavefront_offset" ) {
2993
2993
PARSE_BITS_ENTRY (
2994
2994
KD.compute_pgm_rsrc2 ,
0 commit comments