The longer pasta is cooked, the more water is absorbed into it, and as such it's easier and quicker to break down/digest that starch into glucose.
The same holds true for potatoes. The less it's cooked, the longer it takes to convert into sugar.
slightly undercooked pasta (or many other starches) will be better for your sugars than fully cooked.
Basically, the more it's cooked, the higher the GI of the starchy food. That being said, all starchy carbs will eventually digest into sugar.
You're lucky if you can eat any pasta. 1/2c of cooked pasta spiked me waaay more than I consider safe.