Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Soricidus
Oct 21, 2010
freedom-hating statist shill
please stop posting at&t syntax asm. there's a switch in the options to make it emit intel syntax, as designed by the people who invented the instruction set, rather than the hideous spawn of richard stallman's unix fanfic

Adbot
ADBOT LOVES YOU

taqueso
Mar 8, 2004


:911:
:wookie: :thermidor: :wookie:
:dehumanize:

:pirate::hf::tinfoil:

Soricidus posted:

please stop posting at&t syntax asm. there's a switch in the options to make it emit intel syntax, as designed by the people who invented the instruction set, rather than the hideous spawn of richard stallman's unix fanfic

Sure thing, Intel is more familiar to me anyway, was just hitting the obvious Do It buttons before.

repiv
Aug 13, 2009

AT&T syntax is a coding horror so it belongs in this thread :colbert:


I just noticed the compiler understands the heap, it's completely eliding the heap allocated vector in the first two functions and just doing everything on the stack instead. That's seriously cool.

Apparently neither Clang or GCC know that trick: https://godbolt.org/g/v5h9Pc

repiv fucked around with this message at 23:05 on Mar 9, 2018

vOv
Feb 8, 2014

repiv posted:

AT&T syntax is a coding horror so it belongs in this thread :colbert:


I just noticed the compiler understands the heap, it's completely eliding the heap allocated vector in the first two functions and just doing everything on the stack instead. That's seriously cool.

Apparently neither Clang or GCC know that trick: https://godbolt.org/g/v5h9Pc

I suspect that C++ requires that the vector must actually be allocated because mumble mumble OOM errors or something.

b0lt
Apr 29, 2005

repiv posted:

AT&T syntax is a coding horror so it belongs in this thread :colbert:


I just noticed the compiler understands the heap, it's completely eliding the heap allocated vector in the first two functions and just doing everything on the stack instead. That's seriously cool.

Apparently neither Clang or GCC know that trick: https://godbolt.org/g/v5h9Pc

The ability to replace operator new is required, and replacements are allowed to have side effects, so it has to emit the calls.

repiv
Aug 13, 2009

b0lt posted:

The ability to replace operator new is required, and replacements are allowed to have side effects, so it has to emit the calls.

But Clang does optimize operator new away in this simpler case 🤔

https://godbolt.org/g/B2DaNN

edit: Turns out Clang does elide vectors if you build against LLVMs own stdlib implementation, that optimization just doesn't work with the default GNU stdlib for some reason.

https://godbolt.org/g/rvCgG5

repiv fucked around with this message at 00:59 on Mar 10, 2018

VikingofRock
Aug 24, 2008




Yeah I was a little surprised that clang couldn't make a similar optimization when I played around with it, because both clang and rustc use LLVM as their backend. Needing to account for overriding operator new would make sense, though.

VikingofRock
Aug 24, 2008




Ooh, check it out: I wrote the equivalent in C, and both clang and gcc successfully turn it into a simple comparison. Compilers are so ludicrously cool.

Pixelboy
Sep 13, 2005

Now, I know what you're thinking...
It's like if a clown could literally barf out Visio diagrams

Spatial
Nov 15, 2007

Looks like someone's not an enabler :rolleyes:

Nude
Nov 16, 2014

I have no idea what I'm doing.
Can't board the Agile Release Train™ with that attitude.

Klades
Sep 8, 2011

I was trying to refactor some code in the embedded project I work on. It was a messy affair; massive, over-generalized functions that basically represent actions to perform in response to messages coming over the ethernet connection to the outside.

What was giving me the most trouble was keeping the error reporting all in place without having ridiculously long function signatures. It reports various errors based on whether the number of arguments passed with the command are correct or in the correct amount. After I finally settled on some compromises I went to give it a test run.
All the errors were caught correctly but... none of the error messages were right.

Well, that's not entirely accurate. They correctly stated what was wrong but they weren't the error messages I was expecting.

What's that?

The parsing step before this step actually catches all of these errors in the first place, so none of this error code runs, or has probably ever run?
:eng99:


Just as a bonus: The architecture of the main program involves over a dozen singletons that all expose a bunch of public data members, which are all instances of the same template class, which is basically a jumbled mess of optional callbacks and subscriptions wrapping a single value.

No, we don't have unit tests, why do you ask?

qsvui
Aug 23, 2003
some crazy thing

Klades posted:

embedded project

Klades posted:

No, we don't have unit tests, why do you ask?

sounds about right

pigdog
Apr 23, 2004

by Smythe

Bruegels Fuckbooks posted:

isn't that present tense? i mean, facebook did move from "Move fast and break things" to "Move Fast With Stable Infra," and google has progressed to actually supporting products for longer than a year before the programmers get bored, but job postings are still slobbering all over the agile bullshit, and the visionaries at my company decided to take the SAFe agile poo poo seriously so within the past two weeks, my inbox has been clogged with diagrams that look like:


It's probably an acceptable diagram, except it's targetted to managers 2+ levels above the regular code-writing developers.

bob dobbs is dead
Oct 8, 2017

I love peeps
Nap Ghost

pigdog posted:

It's probably an acceptable diagram, except it's targetted to managers 2+ levels above the regular code-writing developers.

its an acceptable diagram to explain to terry davis the schizophrenic os guy what agile is

Meat Beat Agent
Aug 5, 2007

felonious assault with a sproinging boner

bob dobbs is dead posted:

its an acceptable diagram to explain to terry davis the schizophrenic os guy what agile is

It's larger than 640x480, so no

raminasi
Jan 25, 2005

a last drink with no ice

a hot gujju bhabhi posted:

Anyway, I finally have a coding horror to share. The place I work at unfortunately had a team of very incompetent developers who would do all kinds of crazy poo poo, and I've been meaning to find a tidy snippet without too much business specific stuff in it so I could post it here:

code:
.ForMember(x => x.Fart, opt => opt.MapFrom(src => 
    src.Butt == 2
        ? Constants.SomeInt
        : src.Butt == 3
            ? Constants.SomeOtherInt
            : src.Butt == 5 || (src.Butt == 1 && src.Penis != null)
                ? Constants.YetAnotherInt
                : src.Butt == 1
                    ? Constants.LastInt
                    : Constants.ActualLastInt))
The worst thing? This is from one of the current team members. Magic numbers, chained ternaries, it's a thing of beauty.

If the AutoMapper guy ends up in hell when he dies it will just be an endless stream of poo poo like this that people have done with it.

QuarkJets
Sep 8, 2008

pigdog posted:

It's probably an acceptable diagram, except it's targetted to managers 2+ levels above the regular code-writing developers.

Can you explain why/how the diagram is acceptable? It looks like complete nonsense to me

KernelSlanders
May 27, 2013

Rogue operating systems on occasion spread lies and rumors about me.
We do a safe-ish PI process. It's fine. We get to actually plan out the architecture of a new service before we start writing it but without all the overhead of waterfall.

Jeb Bush 2012
Apr 4, 2007

A mathematician, like a painter or poet, is a maker of patterns. If his patterns are more permanent than theirs, it is because they are made with ideas.

QuarkJets posted:

Can you explain why/how the diagram is acceptable? It looks like complete nonsense to me

managers like complicated-looking diagrams and aren't going to actually read the words or check if the arrows mean anything

Nude
Nov 16, 2014

I have no idea what I'm doing.

QuarkJets posted:

Can you explain why/how the diagram is acceptable? It looks like complete nonsense to me

I was confused as well but then I read "implementing 1 2 3" at the bottom, and was like oh it all makes sense now.

QuarkJets
Sep 8, 2008

I'm the scrum master, dressed up as a referee for Halloween

Which one of you is the RTE dressed up as a train conductor? Can we go trick-or-treating together?

QuarkJets
Sep 8, 2008

Oh whew I was worried that there might not be any quality in this process but there it is, in the bottom right. Glad to know that the quality is built-in, wouldn't want to accidentally make the product lovely!

Nude
Nov 16, 2014

I have no idea what I'm doing.

QuarkJets posted:

Oh whew I was worried that there might not be any quality in this process but there it is, in the bottom right. Glad to know that the quality is built-in, wouldn't want to accidentally make the product lovely!

You seem to have built-in quality but do you have any core-values? It looks like this:

I almost forgot it in my last project.

DaTroof
Nov 16, 2000

CC LIMERICK CONTEST GRAND CHAMPION
There once was a poster named Troof
Who was getting quite long in the toof

QuarkJets posted:

Can you explain why/how the diagram is acceptable? It looks like complete nonsense to me

It looks like the managerial equivalent of writing obfuscated code for job security.

Steve French
Sep 8, 2003

I like the implication that the diagram took 10 years to make

DaTroof
Nov 16, 2000

CC LIMERICK CONTEST GRAND CHAMPION
There once was a poster named Troof
Who was getting quite long in the toof

Steve French posted:

I like the implication that the diagram took 10 years to make

Give them another 10 and they'll be ready to start the first sprint.

Captain Cappy
Aug 7, 2008

Waterfall is a boogeyman made up by the snakeoil salesmen peddling agile to give a reason to companies why they didn't need to hire better managers/leads/developers, and instead just needed to hire me to teach you agile ;)

What is wrong with creating requirements for your thing, designing it, building it, testing it, and maintaining it? It's not even a good strawman but they still made it seem worse than Hitler.

Bongo Bill
Jan 17, 2012

It's a simple idea: you want to minimize the amount of time that elapses between making a mistake and discovering that mistake, so that it's cheaper to fix. Mistakes can happen during requirements gathering, design, and implementation. There are efficient ways to verify that an implementation conforms to requirements, but the only way to verify that requirements conform to user need is by putting it in front of a user, unless of course you're that rare and lucky developer whose users are capable of fully and accurately specifying their own needs.

My head hurts if I look at that chart too much, but it seems to be more about corporate governance than about actually doing work.

Ochowie
Nov 9, 2007

Captain Cappy posted:

Waterfall is a boogeyman made up by the snakeoil salesmen peddling agile to give a reason to companies why they didn't need to hire better managers/leads/developers, and instead just needed to hire me to teach you agile ;)

What is wrong with creating requirements for your thing, designing it, building it, testing it, and maintaining it? It's not even a good strawman but they still made it seem worse than Hitler.

Nothing as long as those requirements never change, designers and developers understand those requirements perfectly, and testers actually remember those requirements when they’re testing.

speng31b
May 8, 2010

Captain Cappy posted:

Waterfall is a boogeyman made up by the snakeoil salesmen peddling agile to give a reason to companies why they didn't need to hire better managers/leads/developers, and instead just needed to hire me to teach you agile ;)

What is wrong with creating requirements for your thing, designing it, building it, testing it, and maintaining it? It's not even a good strawman but they still made it seem worse than Hitler.

Unironic agilefall

TooMuchAbstraction
Oct 14, 2012

I spent four years making
Waves of Steel
Hell yes I'm going to turn my avatar into an ad for it.
Fun Shoe

Ochowie posted:

Nothing as long as those requirements never change, designers and developers understand those requirements perfectly, and testers actually remember those requirements when they’re testing.

You forgot to assume that the requirements were accurate in the first place.

Captain Cappy
Aug 7, 2008

Agile is Prototyping for Dummies with a bunch of unnecessary rules tacked on to justify hiring a consultant, Change My Mind

speng31b
May 8, 2010

Captain Cappy posted:

Agile is Prototyping for Dummies with a bunch of unnecessary rules tacked on to justify hiring a consultant, Change My Mind

Agile is just do things iteratively, you're describing scrum. And yeah when it gets dogmatic about constant rapid user-facing feature delivery to the exclusion of all else that's a fair criticism of it

Captain Cappy
Aug 7, 2008

speng31b posted:

Agile is just do things iteratively, you're describing scrum. And yeah when it gets dogmatic about constant rapid user-facing feature delivery to the exclusion of all else that's a fair criticism of it

Agile is just [Thing I Like About Agile, Not Other Things I Do Not Like About It].

Bongo Bill
Jan 17, 2012

https://twitter.com/PHP_CEO/status/664237197365796864

speng31b
May 8, 2010

Captain Cappy posted:

Agile is just [Thing I Like About Agile, Not Other Things I Do Not Like About It].

Yeah, things don't have real meanings you can verify with a little quick googling.

Captain Cappy
Aug 7, 2008

speng31b posted:

Yeah, things don't have real meanings you can verify with a little quick googling.

https://en.wikipedia.org/wiki/Agile_software_development

This is a long rear end wiki page for "just do things iteratively".

KernelSlanders
May 27, 2013

Rogue operating systems on occasion spread lies and rumors about me.

DaTroof posted:

It looks like the managerial equivalent of writing obfuscated code for job security.

I take it you've never watched an organization pay Oracle to deploy Peoplesoft for them? Two years and a million dollars in they were still "requirements gathering."

Captain Cappy posted:

Agile is Prototyping for Dummies with a bunch of unnecessary rules tacked on to justify hiring a consultant, Change My Mind

That's why you should do agile and not Agile. Find a lightweight process that works for your organization. It should involve shipping imperfect solutions and iterating from there -- no consultants needed.

If you're writing real-time software for aircraft flight control or pacemaker firmware, your process may have to be different, but your web-app doesn't fall into that category. The only thing most businesses need 100% right the first time (and even then, not really) is accounting and for that you should have just bought Quickbooks Pro.

Adbot
ADBOT LOVES YOU

Ochowie
Nov 9, 2007

TooMuchAbstraction posted:

You forgot to assume that the requirements were accurate in the first place.

How about that. Better get the change orders ready.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply