# Strange coroutine optimizations

**URL:** <https://discourse.llvm.org/t/strange-coroutine-optimizations/49986>\
**Category:** LLVM Dev List Archives\
**Created:** [October 8, 2018, 3:52am UTC](https://discourse.llvm.org/t/strange-coroutine-optimizations/49986 "2018-10-08T03:52:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ariya\_Shajii](https://avatars.discourse-cdn.com/v4/letter/a/3be4f8/32.png) [@Ariya\_Shajii](https://discourse.llvm.org/u/Ariya_Shajii)\
**Post date:** [October 8, 2018, 3:52am UTC](https://discourse.llvm.org/t/strange-coroutine-optimizations/49986/1 "2018-10-08T03:52:20Z")

</div>

I was able to reproduce this same issue in C++ using clang’s coroutines.

Gist: [https://gist.github.com/arshajii/48982bd67f6731e43c13923f308d9973](https://gist.github.com/arshajii/48982bd67f6731e43c13923f308d9973)  
Godbolt: [https://godbolt.org/z/ttpHl6](https://godbolt.org/z/ttpHl6)

Ariya
