• What Are You Working On? - December 2014
    1,204 replies, posted
[QUOTE=Cold;46748038]A handful of clients of a consulting company where i used to work, would request everything to be documented with UML class diagrams. Which in the beginning would mean i would take the effort to also start the project with designing the program, creating the UML diagrams, send to them to the client with the early technical documentation. It would always start off nice, neat and simple. But by the time the project came to an end it would be a giant mess regardless of the initial effort. Unforeseen programming stuff would change stuff around, but also a lot of changing client requests, or documentation faults in obscene private 3rd party interfaces. And at the moment there is an actual codebase there, its hard to refractor big pieces of code for sake of implementing a tiny feature, especially when there are deadlines involved. After a few projects like that, i just kinda gave up on it and decided to put my efforts towards refactoring code, and just automatically generate the UML diagrams if the client requested them. I am not saying that you shouldn't use UML or anything like that, but its important that you are realistic about your design, if its bound to change around a lot, or its some kind of experimental/research project, or even something huge with no obvious direction like "Game Engine". Its really not worth your time, unless you have big problems wrapping your head around it[/QUOTE] Couldn't agree more, in my experience UML is something you generate in the end to creat the documentation not something you use when you start the project. Unfortuntetely in the business world, things change, fast. Requirements and features are always receiving modifications and deadlines are important to keep. In short, the industry sees making correct UML diagrams as a waste of time... drawing quick diagrams in a whiteboard it's a very common practice and it's actually useful. Nobody spends too much time on making good UML class diagrams when you have more important things to do.
[QUOTE=false prophet]I feel like mommy and daddy are about to get divorced again. :([/QUOTE] [QUOTE=false prophet;46747832] [/QUOTE]
[QUOTE=sambooo;46740838]Did you actually name your engine "fuck boy"? Christ[/QUOTE] [URL="https://love2d.org/wiki/Category:Libraries"]I think it's a contest.[/URL] [editline]edit[/editline] Since this is [img]http://www.facepunch.com/fp/ratings/clock.png[/img]: [B]What's everyone's stance on not quite obvious/literal library names?[/B] I often use the German word for what it does since they are usually short and really precise (in addition to lowering the collision chance a lot), but it means I sometimes have to explain it to others. (The latter is really my own fault for not immediately including a FAQ though.) [editline]19th December 2014[/editline] [QUOTE=COBRAa;46745898]3D via anaglyph *and* stereoscopy?! Does this allow me to see in 5D?[/QUOTE] The Oculus DK2 apparently has lenses with fairly strong chromatic aberration (which is not surprising considering the small form factor and cost minimization). [editline]19th December 2014[/editline] [QUOTE=elevate;46746400]the hardest part of programming is thinking how the hell you want to do things, typing is the easy part im a perfectionist, i want elegant solutions to problems, not a bunch of sloppy code[/QUOTE] Me too, but what I get is usually elegant [I]and[/I] sloppy. [editline]19th December 2014[/editline] [QUOTE=adnzzzzZ;46745743]I don't like getting bullied because I post gifs.[/QUOTE] Didn't that problem solve itself when some site you use started autoconverting the images? If that's not an option any more for some reason there's also Imgur with its "gifv" thing. Starting with version 33 that should be supported "natively" by Firefox on Windows too.
[QUOTE=Matthew0505;46744282]Why are you dividing and moduloing by powers of 2 if you're that obsessed with execution time, wouldn't >>3 and &7 make more sense[/QUOTE] most compilers do this automatically, and frankly far better than most people can
[QUOTE=EvacX;46749260]most compilers do this automatically, and frankly far better than most people can[/QUOTE] I find the whole "sufficiently smart compiler" thing to be rather ridiculous, as while they optimize loads of things, they aren't all powerful and these kinds of optimizations are [I]sometimes[/I] necessary. The compiler performing an optimization does not necessarily mean it is the optimization you wanted, trading space for speed or vice versa. An interesting page if you're interested in testing gcc/clang/icc etc against eachother as for the assembly they produce: [url]http://gcc.godbolt.org/[/url] But of course, most of the time you shouldn't actually care all that much about optimization before profiling, as you'll just produce horrendous spaghetti :v:
Aaaaagh, someone kill me, I'm trying to look at developer docs for a project I'm on, but it seems like everything on the internet is moving from "functional" to "pretty" Before: [t]https://dl.dropboxusercontent.com/u/20516268/Picts/events%20before.png[/t] After: [t]https://dl.dropboxusercontent.com/u/20516268/Picts/events%20after.png[/t] How long until github turns into a 1-page website [editline]19th December 2014[/editline] Their search box uses size 20 cursive italic font, and the search results have such large text and margins that you can only fit 2 results on the same screen
[QUOTE=Profanwolf;46749519]I find the whole "sufficiently smart compiler" thing to be rather ridiculous, as while they optimize loads of things, they aren't all powerful and these kinds of optimizations are [I]sometimes[/I] necessary. The compiler performing an optimization does not necessarily mean it is the optimization you wanted, trading space for speed or vice versa. An interesting page if you're interested in testing gcc/clang/icc etc against eachother as for the assembly they produce: [url]http://gcc.godbolt.org/[/url] But of course, most of the time you shouldn't actually care all that much about optimization before profiling, as you'll just produce horrendous spaghetti :v:[/QUOTE] That's true when it actually needs to be smart. Semantic optimization is VERY hard. This case however is extremely simple and contained where it only needs to replace divisions by a constant power of two with a right shift.
[QUOTE=Profanwolf;46749519]I find the whole "sufficiently smart compiler" thing to be rather ridiculous, as while they optimize loads of things, they aren't all powerful and these kinds of optimizations are [I]sometimes[/I] necessary. The compiler performing an optimization does not necessarily mean it is the optimization you wanted, trading space for speed or vice versa. An interesting page if you're interested in testing gcc/clang/icc etc against eachother as for the assembly they produce: [url]http://gcc.godbolt.org/[/url] But of course, most of the time you shouldn't actually care all that much about optimization before profiling, as you'll just produce horrendous spaghetti :v:[/QUOTE] "sometimes" as in not this time, the assembly output for multiplying by powers of 2 and bitshifting is exactly the same
Bit-shifting a negative number is implementation-defined in C. It's equivalent to a division if the compiler so chooses. Not all platforms have an arithmetic shift instruction, and so your manually optimized division could potentially be a lot slower or simply wrong.
[QUOTE=polkm;46747952]I finaly have time to program new weapons! [video=youtube;SfNcUuqww0M]http://www.youtube.com/watch?v=SfNcUuqww0M&feature=youtu.be[/video][/QUOTE] I made you some fanart [img]http://i.imgur.com/oSuAEDP.png[/img]
[QUOTE=polkm;46747952]I finaly have time to program new weapons! [video=youtube;SfNcUuqww0M]http://www.youtube.com/watch?v=SfNcUuqww0M&feature=youtu.be[/video][/QUOTE] does this project exist on the internet? this is really cool.
Anyone have any experience implementing AWS' rest API?
[QUOTE=Map in a box;46751632]Anyone have any experience implementing AWS' rest API?[/QUOTE] There's implementations for most platforms, why do you need to implement it yourself?
[QUOTE=Matthew0505;46748944]Yeah but it just seems weird that someone would do syntactic spaghetti hand optimizing and then miss a no brainer hand optimization like bitshifting.[/QUOTE] I'm not sure you understand the purpose of optimization. You optimize code that runs inside of a loop, hundreds of thousands of times. You don't optimize a one-off statement that starts the loop. It doesn't matter. Whether the action takes 1 machine instruction or 4 machine instructions, if you're doing it once it's instantaneous for all intents and purposes. The type of people who would do "syntactic spaghetti hand optimizing" like Duff's device tend to be the type of people who are used to programming in assembly and thought "Well shit, this critical loop will be 6x faster if I unroll it manually because I'm looking at the assembler output and my compiler isn't doing it." For the same reason, these are the type of people who understand that optimization in the way you're describing is pointless. The real moral of the story is that Duff's device has little use today unless you're dealing with a very specific set of circumstances -- you're coding in C, you're running on embedded hardware without a lot of space for program instructions, you're at the limit of program instructions so you had to turn off compiler loop unrolling, there's a critical loop that needs to be made faster and the biggest gain you can get is by unrolling that loop, and your compiler doesn't support some type of "ignore previous settings and optimize this section as much as possible" annotation.
[QUOTE=DrTaxi;46751643]There's implementations for most platforms, why do you need to implement it yourself?[/QUOTE] Because no Lua implementation implements the functions I want or do it horribly and unextendably.
Stuff like this is generally not worth optimizing anyway, even if the compiler doesn't know how to deal with it, You're still on the level of micro-optimizing something based on how many CPU cycles a CPU might spend on certain instructions. Cache hits and misses, Branch prediction, that's the kind of stuff you want to be "micro-optimizing" when you need too, stuff like this is a waste of time in comparison. (I wouldn't be surprised if the IDIV operator on x86 ASM actually does the same bitwise shift when dividing a power of 2)
[QUOTE=Larikang;46750233]I made you some fanart [IMG]http://i.imgur.com/oSuAEDP.png[/IMG][/QUOTE] This made me laugh loudly in a library. I love it. [QUOTE=mutated;46751062]does this project exist on the internet? this is really cool.[/QUOTE] Not yet, I'll release a demo here in a week or two, once some other stuff is in. Finally found a new avatar
Okay so I opened legacy code today and was greeted with this. [t]http://i.imgur.com/rC4qygO.png[/t] I hate my job.
[QUOTE=eirexe;46753937]Okay so I opened legacy code today and was greeted with this. [t]http://i.imgur.com/rC4qygO.png[/t] I hate my job.[/QUOTE] That indentation makes me physically uncomfortable.
[QUOTE=Berkin;46754044]That indentation makes me physically uncomfortable.[/QUOTE] Also dat font rendering
[QUOTE=eirexe;46753937]Okay so I opened legacy code today and was greeted with this. [t]http://i.imgur.com/rC4qygO.png[/t] I hate my job.[/QUOTE] [IMG]https://dl.dropboxusercontent.com/u/10518681/Screenshots/2014-12-20_01-34-57.png[/IMG] Was this written by a 5 year old?
[QUOTE=Rocket;46754114]It's not uncommon for me to write profanity to the console when I'm testing something.[/QUOTE] Yeah but to actually commit that or otherwise submit it as something you're paid to make? I can't imagine this guy still works at that company
I never understood the impulse to swear in trace lines. What's wrong with "test" or "aaaaa".
[QUOTE=Darwin226;46754160]I never understood the impulse to swear in trace lines. What's wrong with "test" or "aaaaa".[/QUOTE] After much testing of something not working, you'll call something a fucking dumbass cunt that you'll kill the fucking family of if it doesn't fucking god damn worked after the FUCKING FIVE HUNDREDTH TIME AND IM ABOUT TO :smithicide:
[QUOTE=Map in a box;46754196]After much testing of something not working, you'll call something a fucking dumbass cunt that you'll kill the fucking family of if it doesn't fucking god damn worked after the FUCKING FIVE HUNDREDTH TIME AND IM ABOUT TO :smithicide:[/QUOTE] If debug prints don't work after 3 tries, it's time to place some breakpoints.
[QUOTE=Darwin226;46754160]I never understood the impulse to swear in trace lines. What's wrong with "test" or "aaaaa".[/QUOTE] I find that exception messages are much more entertaining when they have a bit of attitude. "[B]OHH BLAZING SHITWAFFLES, YOU FUCKED UP [I]REEEEEAL BAD:[/I][/B] System.InvalidOperationException..."
[QUOTE=Berkin;46754251]I find that exception messages are much more entertaining when they have a bit of attitude. "[B]OHH BLAZING SHITWAFFLES, YOU FUCKED UP [I]REEEEEAL BAD:[/I][/B] System.InvalidOperationException..."[/QUOTE] rant generated exception messages
[QUOTE=Map in a box;46754280]rant generated exception messages[/QUOTE] yes needs to be default
i officially hate AWS. who the hell thought it would be a good idea to have the most confusing documentation ever
I don't have anything flashy or exciting to show, but I just spent a solid 3+ hours [URL="https://github.com/Sidneys1/StackingEntities/commit/08ea90ebfeb1bb3592b0293742a987f1dabf2c48"]optimizing my project [/URL]and it just feels SO GOOD. Lots of collecting similar functionality into static classes/methods, caching results of complex methods and etc. An evening well spent.
Sorry, you need to Log In to post a reply to this thread.