From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,21dea4364fec81dd,start X-Google-Attributes: gid1164f8,public X-Google-ArrivalTime: 1992-07-10 20:12:38 PST Newsgroups: comp.sys.dec Path: sparky!uunet!gatech!bloom-beacon!bloom-picayune.mit.edu!ankleand From: ankleand@mtl.mit.edu (Andrew Karanicolas) Subject: Program halts when reading large data file Message-ID: <1992Jul11.091713.9295@athena.mit.edu> Sender: news@athena.mit.edu (News system) Nntp-Posting-Host: mtl.mit.edu Organization: MIT Microsystems Technology Laboratories Date: Sat, 11 Jul 1992 09:17:13 GMT Hello, I've got a question about a C program running on a DEC5000/200. I'm not sure if the error I am seeing is a machine limitation or improper C usage. Here is what happens when the program is run after about 5 CPU seconds: pid 8708 (calibrate04) was killed on kernel acces, at pc 0x4052cc At this point, the program is reading in a large file called "rundata", about 1.2M of ASCII data. This is what the code looks like at this point: main() { FILE *rundata_file; . . /* read in rundata */ rundata_file = fopen("rundata", "r+"); for(i = 0; i <= rundata_length - 1; i++) fscanf(rundata_file, "%d", &rundata[i]); fclose(rundata_file); . . } The input file is something like 191000 lines long so rundata_length is not out of range. Any ideas what is causing the error? Thanks for any help. Please send me e-mail and I will summarize on comp.sys.dec if there is interest. -- Andrew Karanicolas MIT Microsystems Technology Laboratory ankleand@mtl.mit.edu