Repository: rust
Issue: Unoptimized code for big enums (>127 values)
Labels: I-slow,A-codegen,T-compiler,C-bug,C-optimization

I tring to write riscv linux emulator in rust.
I have enum Instruction with 203 values.

For small enums (< 128 values) rustc generates optimized code.
['Small' enum on compiler explorer](https://godbolt.org/#z:OYLghAFBqd5QCxAYwPYBMCmBRdBLAF1QCcAaPECAM1QDsCBlZAQwBtMQBGAVlICsupVs1qhiAVwDOBUpMztkBPHUqZa6AMKpW4gLa0QAdlJr0AGTy1MAOT0AjTMRAA2ZwE5SAB1STCy2lo6%2BkZePn50Fla2ug5Orh5yCkp0DATMxASBegbGiZiK/qnpBJE29o4u7rJpGVnBuTUllmUxFfEAlLKo4sTIHADkAKQADACCgwBMAMyD3ABCbKyoAO4QtHQA%2Biy68lvMchsEAJ6emJLtswAiI6Oe4nYA1Gp6DwCStNISBXQPg4ZzNweQIeAHoQa9AcCzABVV6/f6Q4HA4joEAPcRTCakRFIh54XS6NF4THYsZIv6XUmjJGjWEABQ08IBZNxQJRaIxWJxSPxhLxJJxFKpNMulzhf2Z1NZD3Z6IFLNZxEknA58qlrN5RLV5MMlJxDDMABVxQiFbjZZzhdKlSq5VyzTyCVr7er4XqzQbjdCmdzkai7VbFcrVS7pXinfzQ8ChTiABoAeQASibJWGLdrrcGA76gZrI4G3QWkymczL/ZbSzaQwXHXziVGgTGzaNrGKfQ6/dXK1mKx3cxH6wWm66DWYS32y12J1XsxPJAhmLoCFPXcOkQxE2P266kemG%2BaexnWfPF8vZ6vdQWN6NxzvO%2Be04f90iT0uVzr3a7RqLt2ny0eD1tXs7zZSQJnfaNL31aE5l/a1/2fZEnxrJDwIfSDP3XMwzDgxUEJQ0CgIA3cwIgxsoI9I1cPNfDuyIxDQLQ4CPyvI1vQlStaOnZDuyYgC12BBNE2o3cuJAmUeO4vj9wEoENxwjjpzEx96IIiTpKHCiR0TalFPEvc1JnZjMw0wUtKRJMRPvYyg1U3iyMLHEW0uKy2WUzM7KkhzZIeAAxbBrA0bAfXM4F/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q5fOgaB6AmA2AOBpn%2BBBBhBRAQAJBpAhBVewfIBOhUBPAkSwf%2BhiTGQneCBiT2AxfWANSphQf5Bhf5SIBTA6gDBtTTBShohYhBBvBfAkTw%2B4%2BwgkTo/ygnBtS8huSihahtBshBAs%2BkSc%2Bmgoh0%2BC/Ggk/M/Gg0/WgM/OhJBTu%2BguAVv9v1vNv%2BfgfrfGSHhsfcf8ejgHgIBcBCASBfhphtTOpUAEekfHAx/QqiTDvpArvOf2h7vHvnvQqWqWr7HmOprKPfv/uO/9vQfwfSBIflvSAYfEAQBugCA7gZBUf0eZ%2BM%2BTB8AiAX%2BDfGAWA%2BfTflh1fPA9eQgVvofxu5A99uF3TgA8GWCEBmSXfZAD3xx548Cey/G7qv1IAPcnuL3J7tgJwE4CgB/QP7u31AHA8T%2BEPFfi336ATAQBgPEgWf3IGkAxeSoeUkvCAA%3D%3D)

But, the moment I add one more value it defaults to standard behavior with table of offsets
['Big' enum on compiler explorer](https://godbolt.org/#z:OYLghAFBqd5QCxAYwPYBMCmBRdBLAF1QCcAaPECAM1QDsCBlZAQwBtMQBGAVlICsupVs1qhiAVwDOBUpMztkBPHUqZa6AMKpW4gLa0QAJk6k16ADJ5amAHJ6ARpmJcADC4DMpAA6pJhZbRaOvpGJj5%2BSnSW1na6js6cbp5yCpG0DATMxARBegbGsvKYigEZWQTRtg5Orh6ymdm5IQXS5ZWx8bXuAJSyqOLEyBwA5ACkLgCCo4buo9wAQmysqADuELR0APosuvLbzHKbBACeXpiS3XMAIuMTXuL2ANRqeo8AkrTSEiV0j6MA7PNbo8QY8APRgt7A0HmACqbz%2BgOhoNBxHQIEe4nchlIyJRjzwul0GLw2NxkxRAKu5ImKIm8IAChpEUCKfiQWiMVicXiUYTiQSyXiqTS6VcrgiAazaezHpzMUK2eziJJOFzFTL2fySRrKf9qXiGOYACqSpFK/Hy7mi2UqtUKnkWvlEnWOzWIg0Wo2m2Es3mo9EOm3K1Xqt2ygkuwXh0EivEADQA8gAlM3SiN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LCXzBXXAtJFqXmnnXmXMTJFOIYJ5YVIBMEJr6rSq3UJa30JEwwwvQoyww3AwwpABgwwLgB3qAIAwwyYUgBAbJ/Qgw9J0wQrB3q4x323vQAA1iAO4O4EKaq%2BvX5Tuy4IYAO/PQWbt6vAd0dyd6QGd8MAd5ICADKc9yd70HALAEgGgLoF4HgOwGQBQBABj1jzjyALQHgMAAgAQKwMcKQFQNjwQE4PDxAPYOd1D/YFYFkMcOd5wAdxj7sPQImLQJT8zwd1gIyaIOwEL6QPgMQMUEoAAG7nAS%2B4nFDiB0%2Bc8HdWB0%2B7dQ%2BsB4D2DEDs9aBYAS9ImEhq%2B9A0D0BMBsAcCev8CCDCCiAgASDSBCC6/w%2BQC9CoBeBpDw/DCknMhe8ECknsDy%2BsBanuBw9FCGkQBmBNAGAmBmDtDVAJDeC%2BD%2BB0Bx%2BCDhDp%2B0BJ9xA1AmApAy%2BlANA5DaB5CCBF%2B8llDZB5%2BdCF%2Bl%2BZ8N9tBWBVD58JC9CSC3dDBcA7fnf7eHcS8w/O/MmPAk9k8U/HCPAQC4CEAkB/AzAmDdSoCY/Y9OAL9CskmXfSBPdC/dDvefffdCv/0mv1NrzGu%2Beg/nfg%2BD8vfQ/ndw8I%2BkBI/bekCo%2BIAgD9AED3AyB48E9r8p9MA%2BAIgCnwt6MAWA4vW3isH15eAzeQgfvhDyH7ncHunAR4CsEICskR%2ByAMfqT3J6U9d%2BL3ffqQA%2B5fcfuX3cgRQIoHwDhgN/SHqdwf6yAn%2BL/Igbt0MCIC7%2BMPAgcj16Dy8VQipVeEAA%3D)

I expected to see this happen:
Couple of math instructions

Instead, this happened:
Giant table

### Meta
if I understand correctly, that behavior tie to rust's internal enum type representation i8.  

#### Tried on versions of rustc:
beta
nightly
1.50.0

#### Flags:
-C opt-level=3