diff --git a/src/mapleall/maple_be/src/cg/aarch64/aarch64_abi.cpp b/src/mapleall/maple_be/src/cg/aarch64/aarch64_abi.cpp index 87211148915ec814359543af26eff384ff593476..27e7ae95da4117832ab02f2f92c14cf4d40942cb 100644 --- a/src/mapleall/maple_be/src/cg/aarch64/aarch64_abi.cpp +++ b/src/mapleall/maple_be/src/cg/aarch64/aarch64_abi.cpp @@ -173,9 +173,6 @@ int32 ClassifyAggregate(const BECommon &be, MIRType &mirType, AArch64ArgumentCla if (mirType.GetKind() == kTypeStruct) { MIRStructType &structType = static_cast(mirType); return ProcessStructWhenClassifyAggregate(be, structType, classes, classesLength, fpSize); - } else { - /* mirType->_kind == TYPE_ARRAY */ - CHECK_FATAL(false, "Should not be here"); } /* post merger clean-up */ for (i = 0; i < sizeOfTyInDwords; ++i) { diff --git a/src/mapleall/maple_be/src/cg/emit.cpp b/src/mapleall/maple_be/src/cg/emit.cpp index 7f52078eb7def51b931ec20d348f7b1134841f6c..b37b0ea4c94e63fcc642d9df5734593571e21039 100644 --- a/src/mapleall/maple_be/src/cg/emit.cpp +++ b/src/mapleall/maple_be/src/cg/emit.cpp @@ -1500,8 +1500,10 @@ void Emitter::EmitArrayConstant(MIRConst &mirConst) { } int64 iNum = (arrayType.GetSizeArrayItem(0) > 0) ? (static_cast(arrayType.GetSizeArrayItem(0))) - uNum : 0; if (iNum > 0) { - CHECK_FATAL(!Globals::GetInstance()->GetBECommon()->IsEmptyOfTypeSizeTable(), "container empty check"); - CHECK_FATAL(!arrayCt.GetConstVec().empty(), "container empty check"); + if (!cg->GetMIRModule()->IsCModule()) { + CHECK_FATAL(!Globals::GetInstance()->GetBECommon()->IsEmptyOfTypeSizeTable(), "container empty check"); + CHECK_FATAL(!arrayCt.GetConstVec().empty(), "container empty check"); + } if (uNum > 0) { uint64 unInSizeInByte = static_cast(iNum) * static_cast( Globals::GetInstance()->GetBECommon()->GetTypeSize(arrayCt.GetConstVecItem(0)->GetType().GetTypeIndex()));