<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/compiler/rustc_codegen_llvm/src/debuginfo, branch 1.55.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.55.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.55.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2021-07-09T20:14:44+00:00</updated>
<entry>
<title>Pass type when creating load</title>
<updated>2021-07-09T20:14:44+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>nikita.ppv@gmail.com</email>
</author>
<published>2021-07-04T16:53:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=4560efe46c476cf794fa0ce4efb8db5aa55a3351'/>
<id>urn:sha1:4560efe46c476cf794fa0ce4efb8db5aa55a3351</id>
<content type='text'>
This makes load generation compatible with opaque pointers.

The generation of nontemporal copies still accesses the pointer
element type, as fixing this requires more movement.
</content>
</entry>
<entry>
<title>Respond to review feedback</title>
<updated>2021-07-03T00:38:37+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-07-01T01:53:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f6d2843d6879b5741ab716bd8ca826c2ac5414cb'/>
<id>urn:sha1:f6d2843d6879b5741ab716bd8ca826c2ac5414cb</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Show the variant name for univariant enums</title>
<updated>2021-07-03T00:16:37+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-06-25T17:33:00+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d94f087848ee05036769bd4dc78337ab3604a776'/>
<id>urn:sha1:d94f087848ee05036769bd4dc78337ab3604a776</id>
<content type='text'>
Previously, only the fields would be displayed with no indication of the
variant name. If you already knew the enum was univariant, this was ok
but if the enum was univariant because of layout, for example, a
`Result&lt;T, !&gt;` then it could be very confusing which variant was the
active one.
</content>
</entry>
<entry>
<title>Update directly tagged enums to visualize the same as niche-layout enums</title>
<updated>2021-07-03T00:11:25+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-06-24T20:37:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3780684f5aaceb5f79c00f0c0ce5a96d8edd00ee'/>
<id>urn:sha1:3780684f5aaceb5f79c00f0c0ce5a96d8edd00ee</id>
<content type='text'>
Previously, directly tagged enums had a `variant$` field which would
show the name of the active variant. We now show the variant using a
`[variant]` synthetic item just like we do for niche-layout enums.
</content>
</entry>
<entry>
<title>Improve debug symbol names to avoid ambiguity and work better with MSVC's debugger</title>
<updated>2021-06-30T18:10:29+00:00</updated>
<author>
<name>Daniel Paoliello</name>
<email>danpao@microsoft.com</email>
</author>
<published>2021-06-24T17:36:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=aac8a885520854e4b60ea5733b8b06f9e0cc1fcc'/>
<id>urn:sha1:aac8a885520854e4b60ea5733b8b06f9e0cc1fcc</id>
<content type='text'>
There are several cases where names of types and functions in the debug info are either ambiguous, or not helpful, such as including ambiguous placeholders (e.g., `{{impl}}`, `{{closure}}` or `dyn _'`) or dropping qualifications (e.g., for dynamic types).

Instead, each debug symbol name should be unique and useful:
* Include disambiguators for anonymous `DefPathDataName` (closures and generators), and unify their formatting when used as a path-qualifier vs item being qualified.
* Qualify the principal trait for dynamic types.
* If there is no principal trait for a dynamic type, emit all other traits instead.
* Respect the `qualified` argument when emitting ref and pointer types.
* For implementations, emit the disambiguator.
* Print const generics when emitting generic parameters or arguments.

Additionally, when targeting MSVC, its debugger treats many command arguments as C++ expressions, even when the argument is defined to be a symbol name. As such names in the debug info need to be more C++-like to be parsed correctly:
* Avoid characters with special meaning (`#`, `[`, `"`, `+`).
* Never start a name with `&lt;` or `{` as this is treated as an operator.
* `&gt;&gt;` is always treated as a right-shift, even when parsing generic arguments (so add a space to avoid this).
* Emit function declarations using C/C++ style syntax (e.g., leading return type).
* Emit arrays as a synthetic `array$&lt;type, size&gt;` type.
* Include a `$` in all synthetic types as this is a legal character for C++, but not Rust (thus we avoid collisions with user types).
</content>
</entry>
<entry>
<title>Respond to review feedback</title>
<updated>2021-06-02T14:23:12+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-05-26T16:02:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3127419e2b2cb4ad2e44a06d30af6a015daf4557'/>
<id>urn:sha1:3127419e2b2cb4ad2e44a06d30af6a015daf4557</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Change the type name from `_enum&lt;..&gt;` to `enum$&lt;..&gt;`</title>
<updated>2021-06-02T14:23:12+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-05-20T17:58:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ef053fd6f0faa848097ff8b924ac859c667c8d15'/>
<id>urn:sha1:ef053fd6f0faa848097ff8b924ac859c667c8d15</id>
<content type='text'>
This makes the type name inline with the proposed standard in #85269.
</content>
</entry>
<entry>
<title>Respond to review feedback</title>
<updated>2021-06-02T14:23:11+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-05-17T15:09:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d2d6fa852d22eb4e9259cd708e33e7afaa9211d0'/>
<id>urn:sha1:d2d6fa852d22eb4e9259cd708e33e7afaa9211d0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Make tidy happy</title>
<updated>2021-06-02T14:23:11+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-05-14T15:17:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d65009111734c2a4d89cad5d2fb7bbf08c813b7c'/>
<id>urn:sha1:d65009111734c2a4d89cad5d2fb7bbf08c813b7c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Generate better debuginfo for niche-layout enums</title>
<updated>2021-06-02T14:23:10+00:00</updated>
<author>
<name>Wesley Wiser</name>
<email>wesleywiser@microsoft.com</email>
</author>
<published>2021-05-13T20:39:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=141546c355f2de7501c1df75dd97229ed350eeb3'/>
<id>urn:sha1:141546c355f2de7501c1df75dd97229ed350eeb3</id>
<content type='text'>
Previously, we would generate a single struct with the layout of the
dataful variant plus an extra field whose name contained the value of
the niche (this would only really work for things like `Option&lt;&amp;_&gt;`
where we can determine that the `None` case maps to `0` but for enums
that have multiple tag only variants, this doesn't work).

Now, we generate a union of two structs, one which is the layout of the
dataful variant and one which just has a way of reading the
discriminant. We also generate an enum which maps the discriminant value
to the tag only variants.

We also encode information about the range of values which correspond to
the dataful variant in the type name and then use natvis to determine
which union field we should display to the user.

As a result of this change, all niche-layout enums render correctly in
WinDbg and Visual Studio!
</content>
</entry>
</feed>
