Monkey Ball WarriorA collection of mediocre hatsSeattle, WARegistered Userregular
edited August 2012
I got lucky. I had a professor recommend me to another professor, who hooked me up with an internship, that went well and that I liked, so when they offered me a job paying more than I was expecting I took it.
I managed to completely skip the "looking for a job" part. Which is fine by me, for now.
Monkey Ball Warrior on
"I resent the entire notion of a body as an ante and then raise you a generalized dissatisfaction with physicality itself" -- Tycho
0
GnomeTankWhat the what?Portland, OregonRegistered Userregular
Working on my first "Metro style" (Windows Store) app in VS 2012. The XAML makes sense to me as a WPF guy, but some of it is a bit obtuse. Like the live tile system is odd. You basically can't do "real time" live tiles without using some special cloud service that Microsoft has to approve you for. The rest of us seem to be on 15 minute timers...unless I missed something fundamental in the docs.
I'll be there, if anyone will be there too then let me know.
As for salary, MT, as always comes up the biggest factor is location (cost of living). Whereabouts are you expecting to land work, and what is your experience going to be? I take it you're finishing up school atm?
late reply here, but i graduated with a BS in CS in 2008 (well rounded, had some practical experience - not as mathy as it seems like some of you had), got an MBA, and am currently doing radar engineering work for the next year or so while i pay off student loans. i've done some freelance work since i graduated, but effectively my experience level is comparable to that of a new grad. i'm well aware location is a big factor in pay, but i'm looking at San Fran, NYC, Boston, or Seattle for my next adventure.
When you were graduating, how did you go about looking for jobs?
It seems to me like as a new graduate I'll basically be screwed in terms of what jobs I'm actually qualified for.
i was in ROTC for the air force, so i commissioned and went active after i graduated. i kind of fell into my current job as a guy was retiring the same time i was getting out, so they offered me the position.
Working on my first "Metro style" (Windows Store) app in VS 2012. The XAML makes sense to me as a WPF guy, but some of it is a bit obtuse. Like the live tile system is odd. You basically can't do "real time" live tiles without using some special cloud service that Microsoft has to approve you for. The rest of us seem to be on 15 minute timers...unless I missed something fundamental in the docs.
This is all gibberish to me.
not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
structs are a structured collection of primitive types given unique labels, each member of the struct can be considered to be public in OO models.
0
GnomeTankWhat the what?Portland, OregonRegistered Userregular
The joy of structs is when you realize they are just blocks of sequential, packed, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
The joy of structs is when you realize they are just blocks of sequential*, packed**, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
* Sometimes padded
** Sometimes not quite as packed as you might expect!
Ah yes, I remember working on a program that saved it's states and data right from structs. And then we were scratching our heads, after moving from visual studio 6 to mingw (whatever version) why that data wasn't imported properly. Turns out padding was an issue.
not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
struct s {
unsigned char a[16];
unsigned short b;
unsigned short c;
}
GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
The joy of structs is when you realize they are just blocks of sequential, packed, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
You can also abuse these rules to build a quasi object oriented model by specify your parent struct as the first item in your struct. Next up after that is a manual vtable and you are cooking with bad objects in C.
The joy of structs is when you realize they are just blocks of sequential, packed, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
You can also abuse these rules to build a quasi object oriented model by specify your parent struct as the first item in your struct. Next up after that is a manual vtable and you are cooking with bad objects in C.
Manually keeping track of the vtable? WHERE DO I SIGN UP?
The joy of structs is when you realize they are just blocks of sequential, packed, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
You can also abuse these rules to build a quasi object oriented model by specify your parent struct as the first item in your struct. Next up after that is a manual vtable and you are cooking with bad objects in C.
Manually keeping track of the vtable? WHERE DO I SIGN UP?
The joy of structs is when you realize they are just blocks of sequential, packed, memory, and that the labels you access them with are really just semantic. Knowing type sizes, you can get the exact same information by simply "reading" the memory.
You can also abuse these rules to build a quasi object oriented model by specify your parent struct as the first item in your struct. Next up after that is a manual vtable and you are cooking with bad objects in C.
Manually keeping track of the vtable? WHERE DO I SIGN UP?
not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
0
GnomeTankWhat the what?Portland, OregonRegistered Userregular
It is. It's not standard specified though, C++ compilers are sort of free to do whatever they want in their ABI. There are a few rules around keeping backwards compatibility with C, but the fact that nearly every C++ compiler does the exact same thing when dealing with the vptr is a coincidence of it likely being the best way anyone has come up with yet.
It is. It's not standard specified though, C++ compilers are sort of free to do whatever they want in their ABI. There are a few rules around keeping backwards compatibility with C, but the fact that nearly every C++ compiler does the exact same thing when dealing with the vptr is a coincidence of it likely being the best way anyone has come up with yet.
Mmmmm, I remember debugging vtable management in several C++ compilers and going "Wtf, wait no. FUCK NO." at virtual pointer locations and sizes, but again, this was years and eons ago.
When I was first learning C++, I didn't get why virtual was required and worked in exactly the weird way it did.
When I thought about how things are probably implemented, it started to click.
Fuck doing that myself, C++ is a good thing over that.
Function tables for state machine / microcode in C? Sure.
Framing up my own "classes" in C? Fuck that.
My story was a class assignment formulated as a classic OOP exercise that was limited to C. There wasn't an actual point behind the limitation. A simple case of "Because I said so."(which probably meant "Because, fuck, I don't want to read shitty student C++ code, I'd rather you don't think and write a zillion functions in their separate header files, fuck it."). BUT WHAT DID THAT PROF KNOW THAT I WAS A REBEL BABY? ;o/
I'd really like to get proper reflection for loaded executable code in C/C++ though.
I have an important message about reflection: Fuck reflection and fuck people who use it everywhere. Put them in the same cell with the regex crowd AND LOCK THAT DOOR.
Bowen, if you are one of those, I'll make bowen cut you.
I'll do something like use reflection for serializing of objects for databases automagically and shit.
And it works great, until someone else comes along and tries to work with things but doesn't understand it and breaks the database schema completely. :rotate:
Alright I'm still stuck... When I type "lspci -v" into terminal I see lots of information. Specifically I see our HDDs and they specifically say which kernel driver is loaded for that device. When I type lsmod I don't see any of those drivers in there. is there some other way to see the actual kernel drivers?
0
Monkey Ball WarriorA collection of mediocre hatsSeattle, WARegistered Userregular
Doesn't lsmod only show the modules that are loaded, as opposed to the drivers in use that are baked into the kernel?
"I resent the entire notion of a body as an ante and then raise you a generalized dissatisfaction with physicality itself" -- Tycho
struct s {
unsigned char a[16];
unsigned short b;
unsigned short c;
}
GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
Wait, you're saying the MS compiler doesn't align structs?
I know alignment doesn't matter as much on x86 (as opposed to most of the platforms we ship, which is a wonderfully confusing way to crash the box) but I still thought it was good to align things for performance?
struct s {
unsigned char a[16];
unsigned short b;
unsigned short c;
}
GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
Wait, you're saying the MS compiler doesn't align structs?
I know alignment doesn't matter as much on x86 (as opposed to most of the platforms we ship, which is a wonderfully confusing way to crash the box) but I still thought it was good to align things for performance?
No, it does, but that structure doesn't need any because the shorts are 2 byte aligned to begin with
struct s {
unsigned char a[16];
unsigned short b;
unsigned short c;
}
GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
Wait, you're saying the MS compiler doesn't align structs?
I know alignment doesn't matter as much on x86 (as opposed to most of the platforms we ship, which is a wonderfully confusing way to crash the box) but I still thought it was good to align things for performance?
No, it does, but that structure doesn't need any because the shorts are 2 byte aligned to begin with
The ISO C standard requires that structures are aligned to the lowest common multiple of the alignments of all members of the struct unless packed is specified.
I would expect unions to just be treated as the largest data type in the union.
Doesn't lsmod only show the modules that are loaded, as opposed to the drivers in use that are baked into the kernel?
Yeah that's what it seems like. But I also see:
00:1f.2 RAID bus controller: Intel Corporation 82801 SATA Controller [RAID mode] (rev 04)
Subsystem: Dell Device 047e
Flags: bus master, 66MHz, medium devsel, latency 0, IRQ 41
I/O ports at 4090 [size=8]
I/O ports at 4080 [size=4]
I/O ports at 4070 [size=8]
I/O ports at 4060 [size=4]
I/O ports at 4020 [size=32]
Memory at e1540000 (32-bit, non-prefetchable) [size=2K]
Capabilities: <access denied>
Kernel driver in use: ahci
It says Kernel driver in use: ahci, but I do not see that in the module listing. And when I google "how to see kernel drivers" everything that loads up says "how to see kernel drivers (modules)"
struct s {
unsigned char a[16];
unsigned short b;
unsigned short c;
}
GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
Wait, you're saying the MS compiler doesn't align structs?
I know alignment doesn't matter as much on x86 (as opposed to most of the platforms we ship, which is a wonderfully confusing way to crash the box) but I still thought it was good to align things for performance?
No, it does, but that structure doesn't need any because the shorts are 2 byte aligned to begin with
The ISO C standard requires that structures are aligned to the lowest common multiple of the alignments of all members of the struct unless packed is specified.
I would expect unions to just be treated as the largest data type in the union.
This is what happens as it's the only reasonable thing that can come to pass: figure out each possible data layout given a union, factoring in padding and alignment. The size of the overall union is the largest such data layout that is possible.
@TwitchTV, @Youtube: master-level zerg ladder/customs, commentary, and random miscellany.
Anyone know how to expose the OpenOffice (LibreOffice specifically) com objects for use by other apps? I can't seem to get it to pick up anything and LibreOffice is installed and running. Is there an additional step in the procedure to get the com objects registered? Trying to use spell/grammar check in FoxPro.
not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
That's what I'm looking to tie into, I need spell check and grammar check and we're using MSOffice at the moment but I'm trying to break away from components that don't work in TerminalServices without paying my salary in licensing costs.
not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
Posts
I managed to completely skip the "looking for a job" part. Which is fine by me, for now.
i was in ROTC for the air force, so i commissioned and went active after i graduated. i kind of fell into my current job as a guy was retiring the same time i was getting out, so they offered me the position.
This is all gibberish to me.
struct ide_tp_ops { void (*exec_command)(struct hwif_s *, u8); u8 (*read_status)(struct hwif_s *); u8 (*read_altstatus)(struct hwif_s *); void (*write_devctl)(struct hwif_s *, u8); void (*dev_select)(ide_drive_t *); void (*tf_load)(ide_drive_t *, struct ide_taskfile *, u8); void (*tf_read)(ide_drive_t *, struct ide_taskfile *, u8); void (*input_data)(ide_drive_t *, struct ide_cmd *, void *, unsigned int); void (*output_data)(ide_drive_t *, struct ide_cmd *, void *, unsigned int); };Could anyone explain what this is actually doing? This is in a .h file for one of the ide drivers. This line:
Does this mean I can do something like: ide_tp_ops->exec_command? And then that calls the hwif_s struct?
Yeap, looks like a struct of function pointers to me.
* Sometimes padded
** Sometimes not quite as packed as you might expect!
struct s { unsigned char a[16]; unsigned short b; unsigned short c; }GCC will apparently lay that out as
16 bytes of a
2 bytes of b
2 bytes padding
2 bytes of c
2 bytes padding
as I learned trying to interface with MSVC which has no padding or alignment bytes
To keep compatibility anyways.
You can also abuse these rules to build a quasi object oriented model by specify your parent struct as the first item in your struct. Next up after that is a manual vtable and you are cooking with bad objects in C.
Manually keeping track of the vtable? WHERE DO I SIGN UP?
http://stackoverflow.com/questions/415452/object-orientation-in-c
http://stackoverflow.com/questions/8194250/polymorphism-in-c
I've done it. At the time it made a university professor very, very disappointed.
Mmmmm, I remember debugging vtable management in several C++ compilers and going "Wtf, wait no. FUCK NO." at virtual pointer locations and sizes, but again, this was years and eons ago.
When I thought about how things are probably implemented, it started to click.
Fuck doing that myself, C++ is a good thing over that.
Function tables for state machine / microcode in C? Sure.
Framing up my own "classes" in C? Fuck that.
My story was a class assignment formulated as a classic OOP exercise that was limited to C. There wasn't an actual point behind the limitation. A simple case of "Because I said so."(which probably meant "Because, fuck, I don't want to read shitty student C++ code, I'd rather you don't think and write a zillion functions in their separate header files, fuck it."). BUT WHAT DID THAT PROF KNOW THAT I WAS A REBEL BABY? ;o/
I have an important message about reflection: Fuck reflection and fuck people who use it everywhere. Put them in the same cell with the regex crowd AND LOCK THAT DOOR.
Bowen, if you are one of those, I'll make bowen cut you.
Doesn't bother me that much. Fuck regex though.
And it works great, until someone else comes along and tries to work with things but doesn't understand it and breaks the database schema completely. :rotate:
I don't bother with that much anymore...
Wait, you're saying the MS compiler doesn't align structs?
I know alignment doesn't matter as much on x86 (as opposed to most of the platforms we ship, which is a wonderfully confusing way to crash the box) but I still thought it was good to align things for performance?
SE++ Forum Battle Archive
No, it does, but that structure doesn't need any because the shorts are 2 byte aligned to begin with
The ISO C standard requires that structures are aligned to the lowest common multiple of the alignments of all members of the struct unless packed is specified.
I would expect unions to just be treated as the largest data type in the union.
Yeah that's what it seems like. But I also see:
It says Kernel driver in use: ahci, but I do not see that in the module listing. And when I google "how to see kernel drivers" everything that loads up says "how to see kernel drivers (modules)"
This is what happens as it's the only reasonable thing that can come to pass: figure out each possible data layout given a union, factoring in padding and alignment. The size of the overall union is the largest such data layout that is possible.
That's what I'm looking to tie into, I need spell check and grammar check and we're using MSOffice at the moment but I'm trying to break away from components that don't work in TerminalServices without paying my salary in licensing costs.