JuliaLang/julia — pull request #3429 by tanmaykm (2013-06-17 21:30:48+00:00)
Title: faster readcsv. fixes #3350

Changes to `readdlm` for speed improvements. Instead of `readline` and `split` the new method instead slurps the whole file into memory, parses it linearly for delimiter offsets and uses `SubString` wherever possible.

With this patch:
````
_
_ _ _(_)_ | A fresh approach to technical computing
(_) | (_) (_) | Documentation: http://docs.julialang.org
_ _ _| |_ __ _ | Type "help()" to list help topics
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 0.2.0-2039.r3771bf24.dirty
_/ |\__'_|_|_|\__'_| | Commit 3771bf244d 2013-06-17 22:15:40*
|__/ | x86_64-apple-darwin12.4.0

julia> @time s = readcsv("vList.csv")
elapsed time: 16.183337526 seconds
1608716x9 Any Array:
1.0 166.0 "Govindarajanagar " "RDU3444981" "Mahesh B" "Basavaraju" " ..." 22.0 "M"
2.0 166.0 "Govindarajanagar " "RDU3524188" "Kemparaju" "Chikkanachari" " ." 34.0 "M"
````

Prior to this patch:
````
_
_ _ _(_)_ | A fresh approach to technical computing
(_) | (_) (_) | Documentation: http://docs.julialang.org
_ _ _| |_ __ _ | Type "help()" to list help topics
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 0.2.0-2030.rbf13c7aa
_/ |\__'_|_|_|\__'_| | Commit bf13c7aaf5 2013-06-16 04:52:40
|__/ | x86_64-apple-darwin12.4.0

julia> @time s = readcsv("vList.csv")
elapsed time: 151.918892449 seconds
1608716x9 Any Array:
1.0 166.0 "Govindarajanagar " "RDU3444981" "Mahesh B" "Basavaraju" " ..." 22.0 "M"
2.0 166.0 "Govindarajanagar " "RDU3524188" "Kemparaju" "Chikkanachari" " ." 34.0 "M"
````