Index Error

327 Members
Off-topic conversations for array programming forums10 Servers

Load older messages

27 Sep 2022
@dzaima:matrix.orgdzaima in today's dose of dzaima screaming at utter stupidity: GDB/MI has a command for listing symbols; it gives two different formats, one for symbols which have debug info, and one which doesn't. Worse, the "has debug info" category doesn't give an address for the symbol (whereas the other category does), so having debug info makes the output worse!!! 16:48:43
@dzaima:matrix.orgdzaima by this point it'd probably be easier for me to write a debugger & rr from scratch than try to interface with it through the horrid mess that is gdb 16:52:42
@ngn:matrix.orgngnprintf ftw. best debugger ever.16:52:51
@_discord_687763954050793501:t2bot.ioRaul (Miller) Does the command not have options on display formatting? 16:53:18
@_discord_687763954050793501:t2bot.ioRaul (Miller) (The p command sure has a lot of options...) 16:53:26
@dzaima:matrix.orgdzaima ngn I do stick with printf when possible; but it can't exactly help with finding the past write (from any of the places where memory is written to) that wrote to somewhere it shouldn't have, among many other things 16:54:31
@dzaima:matrix.orgdzaima Raul (Miller) not the gdb/mi command; there's probably the option to parse the regular gdb human text interface instead of the "machine interface", but that's ugly & can break 16:55:14
@_discord_687763954050793501:t2bot.ioRaul (Miller) Hmm... well.. conceptually at least p -address on -- symbol should give you the address of one symbol . 16:56:24
@_discord_687763954050793501:t2bot.ioRaul (Miller) or info address symbol but you probably already knew that. 16:58:09
@dzaima:matrix.orgdzaima that has the issue that there may be multiple symbols with the same name though (singeli currently does this, though that'll probably get changed soon) but info address symbol only gives the address of one 17:01:54
@_discord_687763954050793501:t2bot.ioRaul (Miller) Ah... you're looking across stack frames or some such, I guess. 17:15:00
@_discord_687763954050793501:t2bot.ioRaul (Miller) (And I guess there's nested scopes within a single stack frame, hmm...) 17:15:35
@dzaima:matrix.orgdzaima no, I just wanted a "go to function" which lists functions matching a name, and allows me to view any of them 17:15:39
@dzaima:matrix.orgdzaima I guess it's technically possible to use -symbol-list-lines on the returned filename & get the pc by matching the source line between those; extremely stupid, but probably shouldn't have problems as having multiple symbols with the same name, defined in the same source file, shouldn't be too possible 17:21:25
@dzaima:matrix.orgdzaima oh, obvious counter-example: file #included twice, with a static function with a constant name 17:22:20
@dzaima:matrix.orgdzaima result of that on CBQNs src/core/tyarrTemplate.h; completely unusable - multiple PCs for each line, from each include 17:26:28
@dzaima:matrix.orgdzaima I guess you could then info symbol 0x0000000000406f60 for each confusing pc after that, and map name↔debug line↔possible pc↔symbol, but this is now 3 levels deep in getting something that should be completely utterly unquestionably trivial to get in the first place 17:29:00
@dzaima:matrix.orgdzaima summary: gdb/mi: utter shit. I am probably the only person in the world who has used it for more than 5 minutes (presumably besides the authors, assuming it was even written by humans and not GPT-¯3; my condolences to anyone who was wanted to interface with gdb) 17:40:26
@_discord_886588197562363944:t2bot.ioTrouble "Perigord" Truffle#4324 changed their profile picture.21:05:47
@_discord_595317473247756288:t2bot.ioAlex Shroyer I had to take it in several 20-minute chunks but I finally finished this interview. His general "learn something in a deep way" approach resonates with me. 23:08:03
28 Sep 2022
@ngn:matrix.orgngnguinness record for late reply? :)00:18:12
@_discord_886588197562363944:t2bot.ioTrouble "Perigord" Truffle#4324 changed their profile picture.02:34:20
@_discord_595317473247756288:t2bot.ioAlex Shroyer it was a long interview 12:50:20
@_discord_595317473247756288:t2bot.ioAlex Shroyer I have a graph question, maybe somebody can help.
If I have a digraph with a cycle:
a -> b<=>c -> d

Which I then turn into a DAG via "condensation" (replace strongly connected components with supernode):
a -> bc -> d

Is it then valid to perform any of these edge contractions?
abc -> d
a -> bcd
@_discord_595317473247756288:t2bot.ioAlex Shroyer I'd ping Marshall since I think he was a math major, but I don't know how to ping a matrix user from discord... 12:53:22
@_discord_595317473247756288:t2bot.ioAlex Shroyer Posted it as a mathoverflow question too in case someone wants internet points: https://math.stackexchange.com/q/4540861/149674 12:53:57
@dzaima:matrix.orgdzaima ngn in The Orchard, that'll go to this - 3.7 years; followed by many instances of Adám replying about Dyalog bugfixes, and two messages from me to you 13:03:03
@ngn:matrix.orgngnlol nice13:35:32
@_discord_768182477449592832:t2bot.ioSouth from slightly further down, https://cliki.net/The%20Dying%20Programmers was fun to read 14:51:04

There are no newer messages yet.

Back to Room List