An inconsistency in Hamiltonian formulation for non-local Lagrangian: what am I doing wrong? This question is based on a previous question I asked, Q. [1] 
In this question, I proposed an example of a non-local Lagrangian (functional), I'm revisiting it here:
$$\mathbb{L}=\frac{1}{2}\int^t_0 \left(\dot{q}(\tau)\dot{q}(t-\tau)-q(\tau)q(t-\tau)\right)\,\text{d}\tau
\tag{1}$$
Taking the first variation of Eq. (1) with respect to $q$, I get that the functional is stationary with respect to (neglecting boundary terms):
$$
\ddot{q}(\tau)-q(\tau)=0 \tag{2}
$$
Now, using the approach detailed in the answer to Q. [1] , I formulate a Hamiltonian integral as:
$$
\mathbb{H}=\frac{1}{2}\int^t_0 \left(p(\tau)p(t-\tau)+q(\tau)q(t-\tau)\right)\,\text{d}\tau
\tag{3}$$
Now, taking the functional derivatives of (3), we have:
$$
\frac{\delta \mathbb{H}}{\delta p}=p(\tau),\,\frac{\delta \mathbb{H}}{\delta q}=q(\tau)
\tag{4}$$
Now, as detailed in the answer to Q. [1] , (4) implies that:
$$
\dot{q}(\tau)-p(\tau)=0,\,\dot{p}(\tau)+q(\tau)=0
\tag{5}$$
Substituting the first equation in (5) into the second yields:
$$
\ddot{q}(\tau)+q(\tau)=0
\tag{6}$$
Eq. (6) contradicts Eq. (2), why?
It seems that the non-local nature of the Lagrangian leads to a different set of Hamilton's equations, namely:
$$
\frac{\delta \mathbb{H}}{\delta p}=\dot{q},\,\frac{\delta \mathbb{H}}{\delta q}=\dot{p}
\tag{7}$$
I just assumed this naively (since it would correct the contradiction), is this true, or am I making some mistake in my work?
--
[1] This question deals with the Legendre transform for non-local Lagrangian formulations.
 A: In this answer we apply the general non-local theory developed in my Phys.SE answer here to OP's non-local example. Let us for simplicity assume that time belongs to the unit interval $[t_i,t_f]=[0,1]$. OP's non-local Lagrangian action functional reads (modulo some sign conventions$^1$)
$$ \left. S[q,v]\right|_{v=\dot{q}}, \tag{A} $$
where
$$ S[q,v]~:=~\frac{1}{2}\int_{[0,1]^2}\! dt~du~\delta(1\!-\!t\!-\!u)\left\{ v(t)v(u)  -q(t)q(u)\right\} .\tag{B} $$
The corresponding Lagrangian eq. of motion reads
$$ \ddot{q}~\approx~q,\tag{C}  $$
i.e., exponentially increasing/decreasing solutions. The Lagrangian momentum is 
$$ p(t)~:=~\frac{\delta S[q,v]}{\delta v(t)}~=~v(1\!-\!t) .\tag{D}$$
The Hamiltonian functional becomes
$$ \mathbb{H}[q,p]~=~ \frac{1}{2}\int_{[0,1]^2}\! dt~du~\delta(1\!-\!t\!-\!u)\left\{ p(t)p(u)  +q(t)q(u)\right\} . \tag{E}$$
The corresponding Hamilton's eqs. read
$$\dot{q}(t)~\approx~ \frac{\delta \mathbb{H}}{\delta p(t)}~=~p(1\!-\!t),\qquad 
-\dot{p}(t)~\approx~ \frac{\delta \mathbb{H}}{\delta q(t)}~=~q(1\!-\!t). \tag{F}$$
Note that Hamilton's eqs. (F) imply the Lagrangian eq. of motion (C), as they should.
--
$^1$ We choose sign conventions to match OP's Lagrangian eq. of motion (C).
A: I've found the inconsistency. What follows is a derivation of the Hamiltonian for convolutional Lagrangians.
Starting with the total variation of a convolutional Lagrangian, we have:
$$\delta \mathbb{L}=\int^t_0 \left(\frac{\delta \mathbb{L}}{\delta \dot{q}}\delta\dot{q}(t-\tau)+\frac{\delta \mathbb{L}}{\delta q}\delta q(t-\tau)\right)\,\text{d}\tau \tag{1}$$
Using integration by parts on Eq. (1), we have:
$$\delta \mathbb{L}=\int^t_0 \left(\frac{\text{d}}{\text{d}t}\frac{\delta \mathbb{L}}{\delta \dot{q}}+\frac{\delta \mathbb{L}}{\delta q}\right)\delta q(t-\tau)\,\text{d}\tau+\delta q(t) \left(\left.\frac{\delta \mathbb{L}}{\delta \dot{q}}\right|_{\tau=0}\right)-\delta q(0) \left(\left.\frac{\delta \mathbb{L}}{\delta \dot{q}}\right|_{\tau=t}\right)\tag{2}$$
This implies that for the boundary conditions:
$$
\left.\frac{\delta \mathbb{L}}{\delta \dot{q}}\right|_{\tau=0}=0,\delta q(0)=0 \tag{3}
$$
And the relationship:
$$
\frac{\text{d}}{\text{d}t}\frac{\delta \mathbb{L}}{\delta \dot{q}}+\frac{\delta \mathbb{L}}{\delta q}=0 \tag{4}
$$
The functional is zero. Notice, the relationship in Eq. (4) has a sign change from the typical, Euler-Lagrange equation. This is where the contradiction arises.
Moving on, we define:
$$
 \mathbb{H}=\sup_{v} \left(\int^t_0 p(\tau)v(t-\tau)\,\text{d}\tau-\left. \mathbb{L}\right|_{\dot{q}=v}\right)
\tag{5}$$
To find the $v$  in, we find:
$$
\frac{\delta}{\delta v} \left(\int^t_0 p(\tau)v(t-\tau)\,\text{d}\tau-\mathbb{L}\right)=0
\tag{6}$$
Eq. (6) is true for:
$$
p(\tau)=\frac{\delta \mathbb{L}}{\delta v} \tag{7}
$$
If Eq. (7) is true, we can use Eq. (4) to get:
$$
\dot{p}=-\frac{\delta \mathbb{L}}{\delta q} \tag{8}
$$
Back to Eq. (1), we have:
$$\left.\delta \mathbb{L}\right|_{\dot{q}=v}=\int^t_0 \left(p(\tau)\delta\dot{q}(t-\tau)+\frac{\delta \mathbb{L}}{\delta q}\delta q(t-\tau)\right)\,\text{d}\tau \tag{9}$$
In Eq. (7), we can make the substitution:
$$\int^t_0 p(\tau)\delta\dot{q}(t-\tau)\,\text{d}\tau =\delta \!\left(\int^t_0 p(\tau)\dot{q}(t-\tau)\,\text{d}\tau\right)-\int^t_0 \dot{q}(\tau)\delta p(t-\tau)\,\text{d}\tau\tag{10}$$
This allows use to rearrange Eq. (7) using Eq. (8), as:
$$\delta \!\left(\int^t_0 p(\tau)v(t-\tau)\,\text{d}\tau-\left. \mathbb{L}\right|_{\dot{q}=v}\right)=\int^t_0 \left(\dot{q}(\tau)\delta p(t-\tau)-\frac{\delta \mathbb{L}}{\delta q}\delta q(t-\tau)\right)\,\text{d}\tau \tag{11}$$
The quantity on the left-hand side of Eq. (11) is nothing but $\delta \mathbb{H}$, which is:
$$\delta \mathbb{H}=\int^t_0 \left(\frac{\delta \mathbb{H}}{\delta p}\delta p(t-\tau)+\frac{\delta \mathbb{H}}{\delta q}\delta q(t-\tau)\right)\,\text{d}\tau \tag{12}$$
Comparing the right-hand side of (11) and (12) yields:
$$
\dot{q}=\frac{\delta \mathbb{H}}{\delta p},\,\frac{\delta \mathbb{H}}{\delta q}=-\frac{\delta \mathbb{L}}{\delta q}\tag{13}
$$
Using Eq. (8), we then have:
$$
\dot{q}=\frac{\delta \mathbb{H}}{\delta p},\,\dot{p}=\frac{\delta \mathbb{H}}{\delta q} \tag{14}
$$
Which are Hamilton's equations for this type of convolutional non-local Lagrangian.
