The Australian sharemarket has wiped off its gains for the year on fears of a protracted US-China tariff war and tech sector weakness.