Impacted versions:

[9.0]
Tested in runbot http://174550-9-0-10dcec.runbot10.odoo.com/

Steps to reproduce:

Set the Tax Calculation Rounding Method to "Round Globally" 
Create a Sales Order with the following lines with 7% taxes

1) 5,095.20 
2) 523.20 
3) 80.64 
4) 54.12 
5) 182.00 
6) 186.20 
![image](https://cloud.githubusercontent.com/assets/16055718/19144073/309aa082-8bda-11e6-81d0-2461c4e9a467.png)

Create a Sales Invoice with the same lines with 7% taxes
![image](https://cloud.githubusercontent.com/assets/16055718/19144078/38048b58-8bda-11e6-9c2b-4b501cfa1e12.png)

Current behavior:

The total taxes in Sales Order are $477.48 

The total taxes in Sales Invoice are $477.50 

Expected behavior:

Both the total taxes in Sales Order and Sales Invoice should be 477.50 

Video/Screenshot link (optional):

addons/purchase/purchase.py
'warehouse_id':line.order_id.picking_type_id.warehouse_id.id,
            }
            
            diff_quantity = line.product_qty
            for procurement in line.procurement_ids:
                procurement_qty = procurement.product_uom._compute_qty_obj(procurement.product_uom, procurement.product_qty, line.product_uom)
                tmp = template.copy()
                tmp.update({
                    'product_uom_qty': min(procurement_qty, diff_quantity),
                    'move_dest_id': procurement.move_dest_id.id,  
                    'procurement_id': procurement.id,
                    'propagate': procurement.rule_id.propagate,
                })
                done += moves.create(tmp)
                diff_quantity -= min(procurement_qty, diff_quantity)
            if float_compare(diff_quantity, 0.0, precision_rounding=line.product_uom.rounding) > 0:
                template['product_uom_qty'] = diff_quantity
                done += moves.create(template)
        return done
    @api.multi
    def unlink(self):
        for line in self:
            if line.order_id.state in ['approved', 'done']:
                raise UserError(_('Cannot delete a purchase order line which is in state \'%s\'.') %(line.state,))
            for proc in line.procurement_ids:
                proc.message_post(body=_('Purchase order line deleted.'))
            line.procurement_ids.filtered(lambda r: r.state != 'cancel').write({'state': 'exception'})
        return super(PurchaseOrderLine, self).unlink()
    @api.model
    def _get_date_planned(self, seller, po=False):