|
code:
|
# ? May 28, 2010 17:34 |
|
|
# ? Jun 7, 2024 22:28 |
|
code:
|
# ? May 28, 2010 17:35 |
|
Yeah, writing to the drive is your choke point. Try writing like 100 lines at a time too, that can help.
|
# ? May 28, 2010 17:45 |
|
Awesome. Thanks for the tips, everyone. Especially about the write bottleneck, since I hadn't even considered that mess.
|
# ? May 28, 2010 17:55 |
|
e: posted in Web Programming thread instead
regulargonzalez fucked around with this message at 02:34 on May 29, 2010 |
# ? May 29, 2010 02:31 |
|
furtheraway posted:Awesome. Thanks for the tips, everyone. Especially about the write bottleneck, since I hadn't even considered that mess. Out of curiosity, what are you planning to do with a file of numbers from 0 to 9999999999?
|
# ? May 29, 2010 07:25 |
|
tripwire posted:Out of curiosity, what are you planning to do with a file of numbers from 0 to 9999999999?
|
# ? May 29, 2010 10:26 |
|
Doesn't seem like there's any threads on lua in CoC - not a popular language? Does anyone have a recommendation for an IDE/debugger/code editor for lua?
|
# ? May 29, 2010 21:46 |
|
The Lua-Users Wiki has a list of IDEs and other Lua-aware development environments. There are some debuggers listed here; you may want to just browse the whole LuaAddons section. Personally, I use JEdit. It's not an IDE, but it has a decent lua mode and integrated shell, and is quite customizeable.
|
# ? May 29, 2010 22:00 |
|
HicRic posted:Doesn't seem like there's any threads on lua in CoC - not a popular language? Does anyone have a recommendation for an IDE/debugger/code editor for lua? Not so much unpopular as very popular but within a limited domain. Blotto Skorzany fucked around with this message at 19:06 on May 30, 2010 |
# ? May 30, 2010 01:05 |
|
Cheers, I'll root through those and see what I think.
|
# ? May 30, 2010 19:02 |
|
First admission: I know very little about programming, aside from being able to copy/paste & manipulate PHP. I know a small amount about databases, meaning I can confidently create workable applications in Access, and can find my way around phpMyAdmin. This makes me one of the "experts" at app/database development at my company. I'm currently tasked with creating (ie managing someone who I hire) an application that does this -Allows general access/updating to a SQL database -Has user/admin controls built-in -Allows both online and offline access to updating this database, with corresponding sync capabilities -Pending success, will be significantly expanded upon into a multi-purpose application (first project will ultimately be about 1/10th of the intended use) -Has some reporting features (on this first run, I plan on running most reporting through Access, but ultimately would like to accommodate Crystal Reporting functionality) -Can be eventually expanded into an iPhone app (this one doesn't concern me as much, because I believe it's more dependent on having a logical SQL setup) Second admission: I'm working with a limited budget, and hence, probably working through a freelancing site. That said, I've run multiple successful developments for other applications through these sites, and am ultimately OK with the inherent risks of them. My intended developer is a previous freelancer that I've successfully hired through one of these sites. Running the basic scope of work by them, they have suggested we program it using Silverlight. I know Silverlight is a fairly new system, and supposedly is comparable to flash, but has more universal code integration capabilities. However, I'm a little afraid of the fact that it's compared to Flash, as I know Flash would not be a good solution for what I'm trying to accomplish. His reasoning for Silverlight mainly revolves around the fact that it will provide a consistent interface via a desktop or web app (somewhat important), and will also provide easy updating as the app progresses (very important, since it's a beta). I realize the scope of work might be a little bit vague, and I can clarify where necessary, but does anyone have an opinion on if Silverlight is truthfully a valid solution? Grand Poobah fucked around with this message at 01:07 on May 31, 2010 |
# ? May 31, 2010 01:05 |
|
Silverlight may be a decent technology for what you're looking at. It's essentially a deployment option for .Net languages like C#, so a Silverlight application is probably more comparable to a Java Applet or Java Webstart app than a Flash application. Networking/webservices with WCF are straightforward, so you can interface securely with databases pretty easily. Porting a Silverlight app to the iPhone is bound to be pretty tricky (unless the rumors I've heard about Microsoft releasing a .Net toolchain for the iPhone pan out), but you'd have exactly the same problem with Java. The main question you should ask yourself is "Does this application need to do anything heavyweight on the client side?" ("Heavyweight" can include fancy UIs and graphics, too.) If so, Silverlight is a winner. If not, doing a conventional PHP/J2EE/Python/Whatever webapp might be a more prudent solution that places fewer demands on clients installing plugins and using a particular operating system.
|
# ? May 31, 2010 01:20 |
|
Grand Poobah posted:I'm currently tasked with creating (ie managing someone who I hire) an application that does this Honestly this sounds like a job for Django. Admin comes for free, and you can make some iPhone-specific (or whatever) views or styles. For offline client stuff, use HTML 5's offline stuff like cache manifests and relational store (on iPhone at least, also works in WebKit-based browsers on desktop). You can set up the iPhone site like an app (on the home screen, etc.) Only tricky part here would be syncing changes while offline, but it shouldn't be too bad, and it's really the only part not already done for you. Can't speak to reporting facilities using this setup, so check that out. And your instinct is correct: Silverlight won't run on iPhoneOS.
|
# ? May 31, 2010 20:53 |
|
pokeyman posted:And your instinct is correct: Silverlight won't run on iPhoneOS. I guess I should clarify, I'm not expecting this application to work directly on an iPhone. I fully expect to have to redevelop an iPhone app down the line; I would just want it to be able to tie into the same SQL database. I feel like I'd be limiting the application's capabilities to develop something that would work on an iPhone also. The iPhone would just be to expand the portability of the data.
|
# ? May 31, 2010 21:25 |
|
fixd
Pivo fucked around with this message at 23:24 on May 31, 2010 |
# ? May 31, 2010 21:54 |
|
A stupid Linux internals question that I've not been able to find an answer to: I'm porting a Valgrind tool to 64-bit Linux and the ia32 version had some magic constants corresponding to points in the 32 bit address space, ie: 38 /****************************** globals **************************************/ 39 40 #define TEXT_SEG_BEGIN 0x08048000 41 #define HEAP_SEG_END 0x40000000 42 #define KERN_SEG_BEGIN 0xc0000000 Anybody know what the 64-bit equivilents are, or where I could look these up? Google is failing me, and poking through the enormous source tree isn't yielding any fruit.
|
# ? Jun 1, 2010 23:07 |
|
That's for non-relocatable dynamic library? The segment addresses will be specified on the command line or at the head of some inline assembly.
|
# ? Jun 2, 2010 03:41 |
|
Yeah, I figured it would likely be somewhere in one of the assembly kernel source files since that stuff will have to be set up pretty early on in the boot process, I'd imagine, but I was hoping someone might know offhand which one it would be Grep has been failing me.
|
# ? Jun 2, 2010 17:58 |
|
I do algorithmic trading with a system I built based in Excel. Through a number of VBA macros, it reads real-time market data fed to it from the trading software via a DDE link, the VBA does relatively basic calculations on this data and then uses some functions from the software's API to send orders. This is all relatively simple, and the math/programming is not very complex - most data is manipulated in arrays. The main problem is that it's a bit slow. I need the system to do the math faster for various reasons. I foresee the project to proceeding in 3 stages: 1) Convert some of my VBA functions to C++ compiled functions and linking them as .dlls. 2) Convert my whole set of excel macros into a C++ Excel Add-In (found a copy of this book: Excel and C++ ). Using Excel primarily as flat data storage, data retrieval (from DDE), and graphing. 3) Move the entire system to a self-contained windows program using SQL server or Access (which is fastest for simple tables?) to store and retrieve the data, and have some basic graphing functionality in the main program. Really my main questions are: Will this improve speeds in a general sense? Is C++ the best tool for this job? I don't know any C and would be learning from scratch, though i have reasonable experience with mainly PHP and VBA. I've been learning C++ a little bit, and for what I want to do it seems hard, but do-able over multiple months. Would be my first "big boy" programming language. Am I in over my head trying to move from Excel/VBA to something stand-alone+SQL? mik fucked around with this message at 02:30 on Jun 3, 2010 |
# ? Jun 3, 2010 02:28 |
|
So you know those programming "cookbooks", that are essentially loads and loads of common (or uncommon I guess) real world problem/solution examples? Does anyone know a good book or site that does something similar for database design? At the moment I'm working on a project that will eventually replace a massive (horrible) legacy system I inhereted. Every step of the way I come across something with regards to how the database was designed that has limitations I'd like to overcome. I'll have a couple of ideas and be able to see some pros and cons but I really don't know if I'm missing something obvious or if there is standard way of doing certain things in situations that I'm sure are relatively common. The only resources I've been able to find with a couple of quick searches are more orientated to language/platform specific query design rather than looking at the setup and structure of the database itself. I should add that I'm not realy thinking along the lines of low level database theory. More certain real-world problems and the best way to approach them. Gravy Jones fucked around with this message at 11:37 on Jun 3, 2010 |
# ? Jun 3, 2010 11:32 |
|
I would have thought a 'database refactoring' book might be more useful, off hand I think this book may be useful too: http://www.amazon.com/Working-Effectively-Legacy-Michael-Feathers/dp/0131177052
|
# ? Jun 3, 2010 11:35 |
|
Chrome extension/NPAPI/bundle problem: I'm having a goddamn bitch of a time getting an NPAPI extension to work in Chrome. Right now I'm just trying to get something like npsimple or nixysa or any Hello World type thing to load correctly. What I've done at this point is taken 2 extensions that use NPAPI - 1password, and lastpass, and copied their binary files into the plugin bundle that I made from npsimple, along with modifying the info.plist a bit. If I set the CFBundleExecutable to OnePasswordChrome, it loads. Same with setting it to nplastpass. If I set it to npsimple, or either of the nixysa examples, it can't locate them. "it" being code:
I'd kill for a sample NPAPI project that builds correctly, or any ideas on what I might be doing wrong.
|
# ? Jun 3, 2010 16:27 |
|
mik posted:Will this improve speeds in a general sense? Moving from scripts to machine code will make the calculations faster, but if the calculations aren't the bottleneck, then no. If it takes 5 seconds to get the data, .0005 seconds to crunch the numbers and then 5 seconds to get back to the server with the actions (trades?) to perform based on the input, then making that middle step faster is fairly pointless. If you already know VBA, Visual Basic .Net might be a great deal easier for you to transition into. The tools are free from Microsoft: http://www.microsoft.com/express/Downloads/#2010-Visual-Basic and .Net programs can be about as fast as compiled machine code. You can also do Excel interop from inside .Net and I bet you can make an Excel add-in in .Net if you can make a compiled one in C++.
|
# ? Jun 3, 2010 17:48 |
|
Munkeymon posted:Moving from scripts to machine code will make the calculations faster, but if the calculations aren't the bottleneck, then no. If it takes 5 seconds to get the data, .0005 seconds to crunch the numbers and then 5 seconds to get back to the server with the actions (trades?) to perform based on the input, then making that middle step faster is fairly pointless. I would second using vb.net unless cost is a factor. C++ is very useful for file operations / quick calculations. Best bang for your buck would be using vb.net for everything.
|
# ? Jun 3, 2010 19:38 |
|
SiLk-2k5 posted:C++ is very useful for file operations / quick calculations. What?
|
# ? Jun 3, 2010 20:03 |
|
I don't know about quick file operations. I use bash for that. But I used C++ for quick calculations a bunch of times. Once you get handy with STL and GMP you can compute a lot of stuff relatively quick.
|
# ? Jun 3, 2010 22:38 |
|
Dijkstracula posted:A stupid Linux internals question that I've not been able to find an answer to: None of those values are fixed and if your tool is hard-coding them, it is technically broken.
|
# ? Jun 4, 2010 02:50 |
|
pseudorandom name posted:None of those values are fixed and if your tool is hard-coding them, it is technically broken.
|
# ? Jun 4, 2010 07:43 |
|
Dijkstracula posted:Well, sure, but IIRC they're at least values that can only be changed during a kernel recompile, right? (now, this still doesn't address the original problem of how one can even query for these values) TEXT_SEG_BEGIN is actually determined by the base address of the LOAD segment in the ELF program header, HEAP_SEG_END doesn't have any relation to reality at all (AFAIK), and, yes, KERN_SEG_BEGIN would require a kernel recompile. edit: ok, so KERN_SEG_BASE is obviously PAGE_OFFSET (the offset into the virtual address space where the physical direct mapping starts), and HEAP_SEG_END is apparently supposed to be TASK_UNMAPPED_BASE, but TASK_UNMAPPED_BASE is only loosely related to the heap. It actually controls where the kernel starts looking for empty VM slots to map files via mmap(), so it is sort of an upper bound for where the sbrk() heap could be, except a) malloc will also mmap() anonymous memory for the heap outside of that region and b) if the kernel can't find an empty space in the VM above TASK_UNMAPPED_BASE, it'll search anywhere, including the supposed heap. pseudorandom name fucked around with this message at 09:15 on Jun 4, 2010 |
# ? Jun 4, 2010 08:54 |
|
e: I've got it sorted
poverty goat fucked around with this message at 08:06 on Jun 6, 2010 |
# ? Jun 6, 2010 05:43 |
|
I have an internship with a large company and am put on a large project dealing with ETL and other data warehousing. Although the whole point of most internships is to be dipped into a pool of the unknown, is there anything I can look at dealing with ETL syntax I can look at? I would hate to be the stereotypical "THAT loving INTERN". Everything I have found only talks about HOW it works rather than how to actually use it. Intern jitters are getting the best of me.
|
# ? Jun 7, 2010 06:22 |
|
Do you know how to make coffee?
|
# ? Jun 7, 2010 06:27 |
|
Avenging Dentist posted:Do you know how to make coffee? I drink lots of it but it's not really THAT kind of internship. It pays really well and am basically like one of the employees in both status and responsibility. I guess it's why I am worried about slowing things down a tad.
|
# ? Jun 7, 2010 06:31 |
|
notMordecai posted:I drink lots of it but it's not really THAT kind of internship. It pays really well and am basically like one of the employees in both status and responsibility. I guess it's why I am worried about slowing things down a tad. But that is inevitable even if you were going to be a full time employee, so stop worrying.
|
# ? Jun 7, 2010 06:34 |
|
Is anyone up for letting me harass them with a few stupid IDL questions? Alternatively, are there any good early-level/ reference IDL resources beyond Gumley's text (which I have before me)?
|
# ? Jun 7, 2010 17:34 |
|
pseudorandom name posted:edit: ok, so KERN_SEG_BASE is obviously PAGE_OFFSET (the offset into the virtual address space where the physical direct mapping starts), and HEAP_SEG_END is apparently supposed to be TASK_UNMAPPED_BASE, but TASK_UNMAPPED_BASE is only loosely related to the heap. It actually controls where the kernel starts looking for empty VM slots to map files via mmap(), so it is sort of an upper bound for where the sbrk() heap could be, except a) malloc will also mmap() anonymous memory for the heap outside of that region and b) if the kernel can't find an empty space in the VM above TASK_UNMAPPED_BASE, it'll search anywhere, including the supposed heap.
|
# ? Jun 7, 2010 17:35 |
|
Originally posted this in the maths thread in SAP, and was pointed towards here instead. It's not exactly programming, but anyway: One of the problems in my computational complexity textbook is to prove that L = { M : M halts in 100n^2 + 200 steps } is undecidable. What I'm stuck on is that in constructing a machine to diagonalise it, if it takes more than 100n^2 + 200 steps to decide whether M is in L then I can't flip the output. What silly mistake am I making here?
|
# ? Jun 8, 2010 02:42 |
|
coffeetable posted:One of the problems in my computational complexity textbook is to prove that L = { M : M halts in 100n^2 + 200 steps } is undecidable. I assume you really mean "L = { M : there exists n such that for all inputs, M halts in 100n^2 + 200 steps }" or "L = { M : for all inputs, there exists n such that M halts in 100n^2 + 200 steps }". Because what you just wrote, which would mean "L = { M : for all inputs M halts in 100n^2 + 200 steps }" or perhaps trivially "L = { M : for the empty input M halts in 100n^2 + 200 steps }", is decidable. shrughes fucked around with this message at 04:26 on Jun 8, 2010 |
# ? Jun 8, 2010 04:21 |
|
|
# ? Jun 7, 2024 22:28 |
|
shrughes posted:I assume you really mean "L = { M : there exists n such that for all inputs, M halts in 100n^2 + 200 steps }" or "L = { M : for all inputs, there exists n such that M halts in 100n^2 + 200 steps }". Because what you just wrote, which would mean "L = { M : for all inputs M halts in 100n^2 + 200 steps }" or perhaps trivially "L = { M : for the empty input M halts in 100n^2 + 200 steps }", is decidable. Ah, sorry. I meant L = { M : for all inputs x, M(x) halts in 100|x|^2 + 200 steps }.
|
# ? Jun 8, 2010 04:53 |