Hide Idle (>14 d.) Chans


← 2022-06-03 | 2022-06-05 →
asciilifeform: http://logs.nosuchlabs.com/log/asciilifeform/2022-06-03#1104667 << by default, goes with the endianness of the local machine. arguably oughta nail it down there. could be bothered, if bigendians weren't extinct...
dulapbot: Logged on 2022-06-03 20:14:05 verisimilitude: Does Unsigned_16'Write write big or little endian?
asciilifeform: ( well, e.g. 'm' has a bigendian mode, but even there off by default... )
asciilifeform hasn't a bigendian iron in torture room or in dc, to try on, sadly
asciilifeform: ftr ffa is 100% endianism-free, by design.
verisimilitude: So, as soon as the input must be described exactly, this Ada feature is on the same level as ``look, I named the function which writes it, and call that instead''.
verisimilitude: I'll be stuck reading individual octets to get what I need.
verisimilitude: s/writes/reads/
verisimilitude: I like Ada, but sometimes the chastity cage really itches.
asciilifeform: verisimilitude: what's the problem w/ specifying bit order when the latter actually matters ?
verisimilitude: Well, take that earlier code; the Interfaces.Unsigned_N Write attributes can't be changed, so now either subtypes must be made, or every call changed.
asciilifeform: so make a subtype. e.g. ffa doesn't use naked unsigned_xyz
verisimilitude: By not allowing one to just specify endianness, they're almost useless.
asciilifeform: verisimilitude: in most cases there's 0 reason to giveafuck re endianism
verisimilitude: Common Lisp is actually a little better, because with that I've LDB and DPB.
asciilifeform: when there aint any external wholesale swallowings of unsigned_x for x>8
asciilifeform: ( and when yer only eating what you've previously shat yerself )
verisimilitude: Just disregard me; this sucks in general anyway. Damn near every time I need to get data into a program from a format, it's the most complicated and fragile part of the program.
asciilifeform: in general this is to be blamed on the ctard side
verisimilitude: Yes; there should be no need to do any of this.
verisimilitude: It should be done in the underlying system, but that would actually be useful, so no.
asciilifeform: the obv solution finally, could say, implemented -- the extermination of 'wrong'-endian irons
verisimilitude: Little endian delenda est.
asciilifeform: sure, but will need time machine.
verisimilitude: It's not too late to change Pest to use the proper endian, the network order.
asciilifeform: inherited from extinct sparc ? why ?
dulapbot: (trilema) 2015-04-07 mircea_popescu: which reminds me of a joke : when they entered the eu, the romanians starting bidding on all sorts of contracts. like for instance, a 1947 british rfq to move the country to european style driving.
verisimilitude: Well, we agree on the extermination of wrong endianness.
asciilifeform: erryone, lol, agrees...
verisimilitude: Either big endian or, better, no endian.
asciilifeform: on sane iron -- no endianism (cuz no unaligned access)
asciilifeform: nao where to get any..
verisimilitude: We're back at the start of the circle, again.
crtdaydreams: billymg: new comment re: Gentoo Tut. I think it might've been butchered, the lower half of the comment seems to have disappeared.
crtdaydreams: had a <a href=""></a> tag there, I thought I did, but may not have closed it correctly.
dulapbot: Logged on 2022-06-03 12:36:52 asciilifeform: 's 'official position' to this day -- if somehow suddenly appears a replacement for ada which actually meets asciilifeform's reqs -- would use !
phf: i think the question of endianness is inherently c-ism-- you always have to have a reader and a writer for your data, to use lisp terminology, if you're going to serialize, and your reader should take octets and convert them to internal presentation accordingly. so e.g. read-number -> (logand (ash (read-byte s) 0) (ash (read-byte s) 8) ...)
phf: rob pike maked similar point, and i think his is a solid treatment of subject https://commandcenter.blogspot.com/2012/04/byte-order-fallacy.html
billymg: crtdaydreams: the comment indeed cuts off, even in what i can see in the admin panel. would you like me to delete the comment so that you can resubmit? otherwise you're free to add the chopped off bit in a subsequent comment, up to you
phf: so your reader is built of smaller functions, that are format specific, e.g. you have read-number, read-text, read-array or whatever, which you then combine into larger blocks (defun read-header (s) (let ((version (read-number s)) ...)) (make-%header :version version ...))
phf: which makes endianness or really serialization concerns to be entirely irrelevant. format author might choose to pack his numbers in whatever hairbrained way
phf: i'm a fan of network byte order, which is bigendian, which is that way for historic reasons, and is pretty much all through the rfcs and early specs, but only like it because "it's always been done that way" etc.
phf: ...when specifying network standards
phf: lisp machines including genera had clear dileation of boundaries: if you wanted to read a serialized format you'd have a reader and write for it, but then you store the result in fasl, which is a way to dump any internal representation to disc. so e.g. you read-jpeg -> which gives you image object, which is some struct wrapped arrays, which you then can "save" to a genera fasl if you need to (or keep it in state)
phf: and to further clarify read number: png:read-number would be different from bitcoin-serializer:read-number because the underlying storage formats are different, whether endianness or whatever other concerns
phf: (i prefer to treat everything as a "reader" but "serialize-" or "parse-" are also acceptable terms)
asciilifeform: http://logs.nosuchlabs.com/log/asciilifeform/2022-06-04#1104714 << asciilifeform historically has 'positive associations' with bigendianism -- from assoc. with 'serious irons', salivated over '90s 'workstations' etc. which at one time were 'what one connects to net', vs 'toy' comps where littleendianism was ~exclusively found. but today is rather 'dead hand' imho, the 'serious irons' extinct, and the massaging of endi
dulapbot: Logged on 2022-06-04 13:03:02 phf: i'm a fan of network byte order, which is bigendian, which is that way for historic reasons, and is pretty much all through the rfcs and early specs, but only like it because "it's always been done that way" etc.
asciilifeform: anism is simply waste of kilowattage and a largely pointless mine for n00bs to step on, imho
asciilifeform: and yes as pike et al point out, and as demonstrated in e.g. ffa, if you serialize bytewise, endianism is irrelevant
asciilifeform: sadly not erryone serializes bytewise
asciilifeform: imho the ada way is civilized -- can explicitly mark the expected endianness of a word, and machine will do Right Thing (incl. for bit positions in bitmasks, from which ultimately no escape if yer twiddling bits for 'electric' reasons)
asciilifeform erry time asks bigendian aficionados 'what'd be gained, for the burned cpu cycles, from making a ~new~ protocol 'network-endian' ?' -- gets blank stare
asciilifeform: imho is a (relatively light) symptom of a serious disease, where 'other people's cpu cycles' are considered 'free'
asciilifeform: they aint phree.
asciilifeform must bbl
verisimilitude: http://logs.nosuchlabs.com/log/asciilifeform/2022-06-04#1104725 This is similar to the argument C language idiots use to ignore necessary checks, although the solution really is to just use better hardware, we agree.
dulapbot: Logged on 2022-06-04 13:23:57 asciilifeform: erry time asks bigendian aficionados 'what'd be gained, for the burned cpu cycles, from making a ~new~ protocol 'network-endian' ?' -- gets blank stare
dulapbot: Logged on 2022-06-04 13:27:28 asciilifeform: imho is a (relatively light) symptom of a serious disease, where 'other people's cpu cycles' are considered 'free'
asciilifeform: verisimilitude: the analogy is spurious -- checks win not-bombing. what does turning the bytes around win ?
verisimilitude: It wins consistency.
asciilifeform suspects that if 'little' had won, verisimilitude would still want to turn'em around
asciilifeform: err, 'big'
asciilifeform: i.e. wants not 'consistency' but tamerlan's 'see enemies driven before you, hear the lamentations of their women...' -- which is a legit desire but imho oughta be made explicit.
verisimilitude: Don't use the truth against me.
verisimilitude: Joking aside, I prefer big endian because it matches how the integers are written.
asciilifeform: i.e. in hexdump? indeed does
verisimilitude: We write the most significant digit first, yes.
asciilifeform wonders whether the arabs have 'reversed' hexdumps
verisimilitude: People should be more comfortable reading in multiple ways, really.
verisimilitude: I can read either, but I like little endian less.
asciilifeform: http://logs.nosuchlabs.com/log/asciilifeform/2022-06-04#1104729 << what happened to the old 'hyperrockets will sink all carriers in 5min after war breaks out' notion ?
asciilifeform: dafuq's the point of building'em (other than 'boondoggle')
verisimilitude: Look at the ``ghost cities''.
asciilifeform: consistent.
asciilifeform lives where 'fake construction' endemic, mega-crew closes all but 1 lane of road, grinding traffic to snail's pace, and pretends to lay new asphalt. for years on end. someone pockets the diff, converts to yachts.
verisimilitude: Where I live, they actually lay the new asphalt.
verisimilitude: I've actually seen it.
asciilifeform remembers when occasionally actually saw new asphalt
mats: asciilifeform: china has more hyperrockets
mats: and taiwan doesn't have any
verisimilitude: China claims to have these rockets.
asciilifeform: mats: at some pt both sides will have similar rocket, neh
asciilifeform suspects carrier is a 'ceremonial' item at any rate
verisimilitude: Ideally, one side has all of the rockets.
verisimilitude: That is, one side has all of its rockets unfired, and all of the other side's rockets used.
← 2022-06-03 | 2022-06-05 →