Exactly is an adverb, so you can not use it to modify a noun (tasks). That means your first sentence is not grammatical.
You have two options:
- Exactly which tasks should I perform?
- Which tasks should I perform exactly?
As @StoneyB points out, the second option can be ambiguous.
In the first sentence, exactly clearly modifies which, but in the second one, it seems to modify perform. If it modifies perform, you're asking which tasks should be performed with great(er) accuracy.
The second sentence can, however, also be read as if exactly modifies which, just like in the first one. In that case, the adverb just moved to the end of the sentence, more or less as an afterthought. One might add a comma in that case:
Which tasks should I perform, exactly?
In most cases, I think the second sentence would be interpreted as meaning the same as the first.