mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-27 18:28:14 +00:00
ScopInfo: only run code needed for ASSERT in DEBUG mode
Suggested-by: Johannes Doerfert llvm-svn: 286338
This commit is contained in:
parent
d7407628cc
commit
eba86a1208
@ -4153,6 +4153,7 @@ void Scop::addScopStmt(BasicBlock *BB, Region *R) {
|
|||||||
ScopStmt *Scop::addScopStmt(__isl_take isl_map *SourceRel,
|
ScopStmt *Scop::addScopStmt(__isl_take isl_map *SourceRel,
|
||||||
__isl_take isl_map *TargetRel,
|
__isl_take isl_map *TargetRel,
|
||||||
__isl_take isl_set *Domain) {
|
__isl_take isl_set *Domain) {
|
||||||
|
#ifndef NDEBUG
|
||||||
isl_set *SourceDomain = isl_map_domain(isl_map_copy(SourceRel));
|
isl_set *SourceDomain = isl_map_domain(isl_map_copy(SourceRel));
|
||||||
isl_set *TargetDomain = isl_map_domain(isl_map_copy(TargetRel));
|
isl_set *TargetDomain = isl_map_domain(isl_map_copy(TargetRel));
|
||||||
assert(isl_set_is_subset(Domain, TargetDomain) &&
|
assert(isl_set_is_subset(Domain, TargetDomain) &&
|
||||||
@ -4161,6 +4162,7 @@ ScopStmt *Scop::addScopStmt(__isl_take isl_map *SourceRel,
|
|||||||
"Source access not defined for complete statement domain");
|
"Source access not defined for complete statement domain");
|
||||||
isl_set_free(SourceDomain);
|
isl_set_free(SourceDomain);
|
||||||
isl_set_free(TargetDomain);
|
isl_set_free(TargetDomain);
|
||||||
|
#endif
|
||||||
Stmts.emplace_back(*this, SourceRel, TargetRel, Domain);
|
Stmts.emplace_back(*this, SourceRel, TargetRel, Domain);
|
||||||
CopyStmtsNum++;
|
CopyStmtsNum++;
|
||||||
return &(Stmts.back());
|
return &(Stmts.back());
|
||||||
|
Loading…
Reference in New Issue
Block a user