Place the cubed sweet potatoes in a large saucepan and cover with water. Bring to a boil and cook until the sweet potatoes are fork tender, about 15 to 20 minutes. Drain the sweet potatoes and place in a large bowl.Preheat oven to 350 F degrees. Grease a baking dish and set aside.Add the brown sugar, margarine, cinnamon, vanilla extract, milk, egg and pinch of salt to the bowl with sweet potatoes and mash with a potato masher. You can use a hand mixer as well if you wish.Spread the mashed sweet potatoes in the prepared casserole dish and bake for 30 minutes.While the casserole is baking, add the cornflakes, pecans, butter and brown sugar to a medium size bowl and toss everything together.Top with marshmallows in the center of the casserole, then sprinkle the cornflake mixture around the marshmallows.Place the dish back in the oven and bake for another 10 minutes or until the marshmallows are puffed and golden brown.