« first day (3553 days earlier)      last day (1378 days later) » 

3:01 AM
Kangaroos in the neighbourhood near the farm, picture taken by my drone.
 
 
5 hours later…
8:11 AM
@JerryCoffin so you don't believe that the availability of a language feature changes the idioms you use?
@JerryCoffin and they have several hoops to jump through because they need to account for any kind of allocation pattern, whereas if you preconsidered your allocations you can create a better solution and prevent things like bad locality and fragmentation
 
user7659542
8:29 AM
Am I the weirdo? Mi teamleader has extremely poor coding skills, yet he is the teamleader. He became so because he knows the product well.
 
user7659542
I requested to move to another team because I am tired of him reading my code and getting angry because I implement stuff very differently
 
the higher people are in management the worse they are at the job they manage
 
user7659542
He has been working here for 5 years and has always copy-pasted code (including dead code). I wrote my own code with function pointers and so on and so forth
 
user7659542
he got mad at me because:
 
The Peter principle in practice, eh?
 
user7659542
8:32 AM
- his IDE doesn't know which function "hides" between that function pointer. So just ctrl+click doesn't work any more

- his IDE typically generates his makefiles so it builds everything. I added a subdirectory so his generated makefile was not correct anymore. He got angry because he had to add a path in his IDE. I make my own Makefiles and find it quite easy to just add a path for the sources in there
 
user7659542
- they have legacy code they which does peculiar things. Nobody knows why it does those things, but you have to keep those things there because long time ago there was a meeting and they decided to put it there. But nobody wrote anything down and nowadays nobody knows the reasons behind this
 
user7659542
- 3 months ago I organized a meeting with the lead SW engineer and the architect explaining the new software architecture I suggested and how I was going to start implementing it. Now, 3 months later, that teamleader (who was not in that meeting) sees my code for the first time and gets extremely angry asking why the f*ck I am adding so many new things in the code (eg new architecture) and this is unacceptable. He said he wants to revert all my commits.
 
user7659542
Architect (5years of xp) told me he didn't understand what I was trying to do and didn't have to time to look at it. Lead SW engineer (20+ years of xp) agreed from the start with my approach.
 
user7659542
@PeterT idk, maybe... He started working at this company 5 years ago right after graduating and became teamleader here.
 
user7659542
Also another fun thing
 
user7659542
8:42 AM
the current company I am working at wants to create "autonomous teams", ie a very horizontal hierarchy where all teams are asked to develop something and work on it without having an internal leader
 
user7659542
teams of +/- 5 ppl
 
user7659542
how on earth is this ever going to work?
 
user7659542
For me autonomous teams, just means you re a bunch of lazy cunts who do not want to actively manage things and make sure things go in the right direction. Instead you just offload everything to the devs and if it doesn't work its his fault
 
random managers get to email random people to get something done
 
user7659542
and you, manager/temleader, can just keep on doing nothing and arriving at the office at 11am
 
8:45 AM
instead fo havigg to trickle down the hierarchy
 
@traducerad It would work in a company started by a group of people with similar interest & a common goal, but not in a company who hires people who mainly go there for a salary.
 
user7659542
This also means ambitious people will never be able to evolve to a lead sw engineering role or an architect role
 
Ambitious people would attempt their own business.
 
user7659542
due to this horizontal new hierarchy almost everybody is equal
 
user7659542
@TelKitty you mean running their own business?
 
user7659542
8:52 AM
That's my biggest dream. I just need to find a proper idea. I m totally able to spend entire nights working on side projects and completing them.
 
user7659542
But I am unable to see real business opportunities or holes in the market
 
traducerad Sounds like you decided to change a functioning system nobody cares about, then changed some dudes pet project. This sounds irritating but also a waste of time from a business perspective. Not good.
 
user7659542
It amazes me how so called "innovation managers" at companies are able to keep having new ideas and seeing opportuities all the time. I am just unable to see such things.
 
Yes. But I use the word 'attempt' because you might not be successful the first time. If you are truly talented, you will generally become better as you fail. Eventually you might even succeed because opportunity favours the prepared.
 
user7659542
@Mikhail what do you want me to do? Just copy paste code like those other morons?
 
user7659542
8:56 AM
You know nowadays when something does not work in their product (some bug or so) it is a real pain in the ass to find the source, because:
 
@traducerad That's because those companies tend to have a lot of capital.
 
user7659542
- their code is extremely poorly written
- source files are sometimes 8k+ lines
- shitload of dead code
- so much useless stuff, here is a great example seen in their code: #define INIT_STRUCT(_str_) memset(&_str_, 0, sizeof _str_);
- etc...
 
Foremost it seems like whatever project you were trying to start nobody cared about, it appears that none of your coworkers even wanted to speak with you about it.
 
user7659542
@TelKitty OK, but I was referring to that skill. Having that skill is quite something IMO
 
They also have more resources, like lots more data and more time to capture and analyse the relevant information.
 
nwp
9:07 AM
It's part of your job to point out issues and make an attempt at fixing them. If you don't have team members you need to convince them that your change is good. Having someone do code-review on an architecture change without knowing anything about the architecture obviously will not work out. Maybe you should have prepared a summary of the change for them to look at.
Then again it sounds like at this point getting a better job is easier.
 
user7659542
@nwp pay is not too bad here. I'll try moving to another team, where I can learn new skills (eg hardware development & VHDL). If I don't manage to switch to another team I have no real reason to stay at that company
 
user7659542
I currently have the impression the teamleader doesn't want me to switch
 
HDL is really tedious (also I hope you mean verilog). You're going to find yourself spending hours taking something that adds numbers.
 
user7659542
Probably because I am doing part of his work. So if I leave he ll have to work more
 
user7659542
@Mikhail I don't mind at all doing HDL. I tend to like it. Also, as a contractor, I have noticed the field doesn't pay too bad either
 
user7659542
9:12 AM
VHDL not verilog
 
So, I used to teach an HDL class. Basically, we shifted to verilog like 10 years ago. Its about 2x faster to "code" in.
 
user7659542
no not necessarily creating adders in VHDL. Currently looking at: writing a I2C module in VHDL and a module which allows to communicate via PCIe
 
user7659542
so that sounds very interesting IMO
 
user7659542
I ll also have to write a kernel module to communicate via PCIe if I manage to switch
 
user7659542
@Mikhail didn't know it was that faster. How come?
 
9:15 AM
Oct 29 '19 at 1:20, by Mikhail
@JerryCoffin Talking about vintage circlejerk, remember this debate? http://athena.ecs.csus.edu/~changw/class_docs/VerilogManual/cooley.html
So, when I was an undergrad some decade ago, I got a job offer to do HDL where my first task was to be migrating VHDL to verilog. I noped out of that almost immediately.
Prasad Paranjpe
    Synopsys Marketing
    1995 – Present 25 years
    mostly financial analysis and modelling
    still do some market share analysis
    ... but in marketing not finance :)

    LSI Logic Engineer
    1992 – 1995 3 years
    Headland reacquired as business unit - forgot BU name
Fun to see what happened to some of these guys
 
9:46 AM
@ratchetfreak It can to some extent, undoubtedly. But it's a long jump from "features can affect idioms" to "RAII causes allocations". Like, a leap of many billions of light years.
@ratchetfreak The point isn't that you can't do any better. The point is that virtually all allocations anybody has done for many years have always been of exactly the form your described: allocate a big chunk, then divide it up for others to use.
 
9:58 AM
but the api available forces concessions on both sides,
the malloc api has only the pointer to the start of the block,
this means that the implementation needs to have some mapping to the meta information of the allocation (either a map structure or a pre allocation header) adding bloat to the allocation or inefficiencies during alloc or free
the usage code cannot assume anything about locality of allocations
whereas if you analyzed your allocation patterns you can get a better allocation scheme for your usecase
if you find that you have a churning set of fixed sized objects: make an object pool with freelist. If you find a FIFO pattern of allocations: make a stack allocator
and most allocator that see large enough allocations to do those things will bypass their internal structures anyway and punt straight to the kernel
 
10:23 AM
@traducerad You are using an objective function of maximizing "product quality" (to your taste). As an experiment instead trying maximizing "happiness of coworkers" and see how that works for you. You can change roles, but this problem will follow you even into elite organizations. You can try to start a business, but that's less likely to work than you think, and your odds will be worse if you haven't run this experiment.
 
user7659542
10:46 AM
@kevinlawler I m paid to make the best product possible, not to make my colleagues happier. I am not a clown
 
user7659542
yet
 
the best product possible is mostly unrelated to code-quality unless you're selling the SDKs
 
user7659542
@PeterT well yes and no
 
user7659542
if you re building a framework. If you re framework is well written and allows good modularity company will win time when using you well written framework
 
user7659542
currently their framework is shit and needs to be updated every single time when you use it because it does never fit their needs
 
10:49 AM
I'm still doubful of large refactor/rewrites being a plus to the product. I've only ever seen them make an impact on "developer satisfaction", rarely have I seen the time being invested pay dividents for the product
 
user7659542
well thought/written framework = smaller time to market
 
You would think so, haven't seen much conclusive evidence there though
 
user7659542
11:37 AM
How to test assemby code?
 
user7659542
One of the first answers online:
 
user7659542
by statically parsing the assembler without running the compiled program, because it is too difficult
 
@traducerad it's called agile... you should do the training
 
user7659542
@Mgetz Since when is agile synonymous for lazy?
 
@traducerad That's not what it means at all... do the training
@traducerad it's not? which is why I was surprised you were viewing it that way
you can use agile to get what you want by building consensus
@traducerad use the strangler pattern. Rewrites inevitably never get delivered
 
 
2 hours later…
1:22 PM
@traducerad Shrug. When you get tired of banging your head against the wall, try it the other way.
 
user7659542
1:40 PM
bool iss_sf = opc == 0 ? 32 : 64
 
user7659542
huh what is this supposed to do? I don't get it
 
user7659542
aren't you putting an int in a bool? (eiter 32 or 64)
 
@traducerad if that's C check to see what the typedef of bool is...
 
user1804599
@Mgetz We delivered a rewrite two years ago and it’s been running better and been more maintainable than the original code base ever did or was.
 
it's not that uncommon for it to be typedef bool int;
 
user1804599
1:42 PM
The rewrite took about one and a half year and it was fun and effective.
 
@rightfold Then you're the exception. Most cases you're better off doing strangler pattern
 
user1804599
I don’t think so. The trick is that you should apply competence, which people rarely do.
 
/facepalm
relying on people to apply competence is asking for trouble
 
user1804599
It’s called being good at hiring. If you can’t do that and you’re in charge of hiring then you’re already doomed. :noel:
 
nwp
Just do the right thing and it'll work out. Easy.
We did rewrites too and they were much better and get delivered.
Though in our case the reason for that is that the first time nobody knew what the result is supposed to look like. The rewrite had that problem much less.
 
user7659542
2:16 PM
if I were to run a unit test inside an emulator
 
user7659542
is it usually possible to obtain the result from that run test on the host?
 
save the result to a file in the emulator and copy over the file
that makes it possible to easily run the tests on a real device too and compare the result
 
user7659542
@PeterT myea I guess
 
user7659542
now only thing left to do is find an emulator which can actually emulate my device
 
if there's no real emulator you can always just use the real device
 
user7659542
2:20 PM
@PeterT I don't know if that would be the clean way to proceed
 
user7659542
it s a 16bit device, whose code is entirely written in asm
 
user7659542
they now want to write official tests for everything
 
user7659542
I m thinking about wrapping the asm code in C
 
user7659542
so I can then use more mainstream test frameworks and other tools
 
so what? all you need to do is connect it to a host device that can reprogram it and capture some output (i.e. via serial)
 
user7659542
2:22 PM
@PeterT yes, that's how I would do it at home too :p
 
user7659542
but I don't know whether that is the "clean & most professional" way for a company
 
well you don't run it on your machine when you do it professionally, you connect it to a test-runner
 
user7659542
I thought maybe using some sort of emulator would be cleaner, but I have no experience at all with that kind of stuff
 
user7659542
@PeterT also what about lcov if I run everything on that device?
 
nwp
Why would the emulator be cleaner? It's worse. The emulator is not the real device and it's not perfect. The only reason to use an emulator is because you don't have enough real devices and the emulator is close enough that it's still useful.
 
user7659542
2:23 PM
I think adding lcov in the testsetup would be a nice added value
 
user7659542
@nwp true
 
user7659542
it is actually the most realistic
 
I don't know if I'd ever bother coverage testing asm code
 
@traducerad qemu?
 
but that's mostly because I'd try to avoid asm as much as possible an relegate it to small corners
 
user7659542
2:25 PM
@Mgetz doesn"t support the device I am looking for
 
user7659542
MSP430
 
user7659542
found a 5 year old for from qemu which contains some support
 
darn, I know that there was at least one person on the committee that actually ran tests on hardware and emulation
(in C++ btw)
 
user7659542
it s been 30 minutes and still have not managed to compiled their fork
 
user7659542
keep running in compilation errors one after the other
 
2:27 PM
did they list compatible compilers?
 
user7659542
@Mgetz Nope
 
nwp
Setting up a working build environment tends to take days, not hours.
 
user7659542
@nwp at all the companies I have worked at it always took a couple of hours at most
 
user7659542
(IDK about boost and such though...)
 
2:29 PM
in this case it's so far behind qemu master I'm not sure it wouldn't take weeks
assuming it's accurate at all
 
nwp
Maybe my view is a bit skewed here since we do hardware and making an LED blink and a breakpoint getting hit is a huge accomplishment.
 
user7659542
@nwp same here
 
user7659542
you can set up a test environment where you neglect the HAL
 
user7659542
smth with CMocka
 
user7659542
setup and installation for this doesn't take too long
 
2:31 PM
I recall reading the test harness someone set up for something like that, the test consisted of the emulator and a non-emulated test harness that checked things like pins
the hardware test rig was much more complex and involved all sorts of hardware to plug into the same test code
 
user7659542
Indeed if you write code which toggles pins and want to test that you need an external setup which measures those pins to confirm this works
 
So as far as I know they tested externally even in emulation
they just had software emulation for fast tests and CI and hardware tests for validation
 
user7659542
3:01 PM
@PeterT if it is a regulated industry you'll have to test your testbench
 
user7659542
and then you test the testbenche's testbench
 
user7659542
testbenche's testbenche's testbench
 
user7659542
etc
 
but you think an emulator would have fewer requirements?
 
user7659542
how do people get out of this infinite loop typically?
 
3:41 PM
Today I learned about this:
```
void has(void) { return; }
void get(void) { return has(); }
```
As useful as a break statement but for a function... -_-
 
nwp
return illogical ? throw std::logic_error{} : throw std::runtime_error{};
 
4:36 PM
Depends on if the context of `illogical` is compile-time or run-time, right?
(Although it seems like it should be `std::logic_error` on the surface because it's `illogical`...)
I think the reason its taking forever for me to build "general-purpose" (don't ask me what that means) utility libraries is because of the very nature of learning to code. The learning part, that is.

Because I'm constantly learning "new" features, practices and disciplines the libraries I try to write (and finish) keep getting more robust with code that mandates refactoring (and personal deadlines keep getting missed).

Now the question is, how the heck do I get out of this kind of development hell?
Context: It's been two years since I've been trying to write a utility C++ and JavaScript library now and that's two years too long for me that I ain't getting back... |:(
@traducerad break statement, uncaught exceptions, or sentinel conditional variables(?)
 
user7659542
4:56 PM
@Lapys yes.
 
user7659542
8:29 PM
Q: How to write unit tests for openGL?
 
user7659542
A: You cannot automatically test rendering part. For that you'll need an sentient being with ability to see and recognize images. Computer doesn't qualify.
 
user7659542
Not gonna lie, I laughed
 
user7659542
sentient...
 
You can easily do some simple reference image comparison to textures
I've done approval tests that involve opengl
 
user7659542
@PeterT You should tell this to SigTerm
 
user7659542
8:38 PM
4
A: Learning OpenGL while practicing TDD (unit testing)

SigTermYou cannot automatically test rendering part. For that you'll need an sentient being with ability to see and recognize images. Computer doesn't qualify. You can automatically test for succesfull resource creation - VBO, textures, shaders, display lists - , you can unit test shaders for compilati...

 
8:56 PM
^ [[gnu::pure]] doesn't seem to enforce purity, which is sad. Seems like it just makes touching external state UB. I was kinda hoping it would have some associated warnings or even choke the compiler.
[[gnu::pure]] int something() {return not_pure();}; <- Would be cool if this was a compiler error...
Also would be pretty cool if we have automatically memoization by using self modifying code :-)
One day we will have the language we deserve.
 
 
2 hours later…
10:46 PM
 

« first day (3553 days earlier)      last day (1378 days later) »