| 245 | } |
| 246 | |
| 247 | void BeIRCodeGen::Hash(BeHashContext& hashCtx) |
| 248 | { |
| 249 | // if (mBeModule->mModuleName == "IDE_IDEApp") |
| 250 | // { |
| 251 | // hashCtx.mDbgViz = true; |
| 252 | // NOP; |
| 253 | // } |
| 254 | |
| 255 | hashCtx.Mixin(mPtrSize); |
| 256 | hashCtx.Mixin(mIsOptimized); |
| 257 | if (mBeModule != NULL) |
| 258 | mBeModule->Hash(hashCtx); |
| 259 | |
| 260 | Array<BeStructType*> structHashList; |
| 261 | |
| 262 | for (auto beType : mBeContext->mTypes) |
| 263 | { |
| 264 | if (!beType->IsStruct()) |
| 265 | continue; |
| 266 | auto beStructType = (BeStructType*)beType; |
| 267 | if (beStructType->mHashId != -1) |
| 268 | continue; |
| 269 | structHashList.Add(beStructType); |
| 270 | } |
| 271 | |
| 272 | structHashList.Sort([](BeStructType* lhs, BeStructType* rhs) |
| 273 | { |
| 274 | return lhs->mName < rhs->mName; |
| 275 | }); |
| 276 | |
| 277 | for (auto beStructType : structHashList) |
| 278 | { |
| 279 | beStructType->HashReference(hashCtx); |
| 280 | } |
| 281 | } |
| 282 | |
| 283 | bool BeIRCodeGen::IsModuleEmpty() |
| 284 | { |
nothing calls this directly
no test coverage detected