mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-17 11:13:27 +00:00
Revert "Move coroutine passes from Makefile to compiler itself"
This reverts commit d9ca5f97fb.
There is a problem with coroutines that I haven't solved yet. Reverting
makes it work, for now.
Also, use a better coroutines flag for the LLVM opt tool.
This commit is contained in:
@@ -1746,12 +1746,8 @@ func (c *Compiler) Optimize(optLevel, sizeLevel int) {
|
||||
builder.PopulateFunc(funcPasses)
|
||||
|
||||
modPasses := llvm.NewPassManager()
|
||||
modPasses.AddCoroEarlyPass()
|
||||
modPasses.AddCoroSplitPass()
|
||||
modPasses.AddCoroElidePass()
|
||||
defer modPasses.Dispose()
|
||||
builder.Populate(modPasses)
|
||||
modPasses.AddCoroCleanupPass()
|
||||
|
||||
modPasses.Run(c.mod)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user