Look, I came up with this mixed solution that seems to work way faster. I created a 1 million sample random data like the one you mentioned above and timed your code. It took 77 seconds in my Mac computer which is a super fast computer by the way. Using numpy to split the string instead of shlex ended up in a 5 seconds processing process.
A=[0]*len(matrix)
B=[0]*len(matrix)
C=[0]*len(matrix)
for i in range(len(matrix)):
full_array = np.fromstring(matrix[i], dtype=float, sep=" ")
A[i]=full_array[0]
B[i]=full_array[1]
C[i]=full_array[2]
I made a couple of tests and it seems to work well and it's 14 times faster. I hope it helps.