def gen_arg_addrspace_md(fn):
    mod = fn.module
    fnty = fn.type.pointee
    codes = []

    for a in fnty.args:
        if cgutils.is_pointer(a):
            codes.append(SPIR_GLOBAL_ADDRSPACE)
        else:
            codes.append(SPIR_PRIVATE_ADDRSPACE)

    consts = [lc.Constant.int(lc.Type.int(), x) for x in codes]
    name = lc.MetaDataString.get(mod, "kernel_arg_addr_space")
    return lc.MetaData.get(mod, [name] + consts)
Prepare the indexer by initializing any required variables, basic
dataset/ETHPy150Open numba/numba/numba/hsa/target.py/gen_arg_addrspace_md--crossover with--dataset/ETHPy150Open numba/numba/numba/targets/arrayobj.py/Indexer.prepare