Idea behind Compactified Boson On p. 167 of his Conformal Field Theory, Di Francesco introduces "Compactified Boson". He says:

The invariance of the free-boson Lagrangian [...] with respect to translations $\varphi(x) \rightarrow \varphi(x) + \text{const.}$ means that it is possible, without modifying too much the dynamics of the field, to restrict the domain of variation of $\varphi(x)$ to a circle of radius $R$.

thus giving $\varphi$ an angular variable character. I don't fully understand the later part of the statement. Could somebody please explain this to me in some detail? Also, later he introduces a generalized boundary condition on $\varphi$:

$$ \varphi(x+L,t) \equiv \varphi(x,t) + 2\pi m R, \tag{6.90} $$ 

where $m$ is the winding number. I don't understand the physical motivation behind this and its similarity with the classical $XY$ model?  
 A: Notice first that even before restricting the domain of $\phi$, we are considering the theory on the cylinder and identifying the boundary condition $\phi(x + L,t) = \phi(x,t)$.
Now to explain the restriction, let's take this example. Consider a field configuration at some fixed time $\phi(x,0)$, we only have to study this in the domain $[0,L]$. Now pick any constant $R$, and as a consequence of the invariance, at this fixed time the two functions $$\phi_I(x) \equiv \phi(x,0) \text{ and }\phi_{II}(x) \equiv \phi(x,0) - 2\pi R$$
Are physically indistinguishable.
Now suppose for the sake of explanation that $0<\phi_I(x)<2\pi R$ for some interval $[0,L_1]$, and $2\pi R<\phi_I(x)<4\pi R$ for $[L_1,L]$. 
Now define a new field configuration $$\phi'(x) =\left\{\begin{array}{cc} 
\phi_I(x) & x\in[0,L_1] \\ \phi_{II}(x) & x\in [L_1, L]
\end{array}\right.$$
Then physically this function is equivalent due to shift invariance, however now $\phi'$ is restricted to always satisfy $0<\phi'<2\pi R$.
Once you understand this procedure, it should become clear that the boundary condition $\phi(x+L,t) = \phi(x,t)$ "before" restricting the domain, is equivalent to $\phi(x+L,t)=\phi(x,t) + 2n\pi R$ "after" restricting the domain, where now $\phi'(x+L,t)=\phi'(x,t)$. But as you can see, even though this is locally equivalent to the previous boundary condition, it is more general, because we don't have to require that the pre-restricted field configuration is identically equal at the boundary, and $n$ can be understood as winding number because after we went around the cylinder once, the pre-restricted field configuration changed, so even though (locally) pre and post restriction are the same, we must account that at the boundary there is something going on (globally)
A: Let us suppress (world-sheet) time $\tau$ in what follows, i.e. consider a fixed time $\tau$. Let there be given a continuous map $\phi:\Sigma\to M$, where the world-space $\Sigma$ and the target space $M$ are both 1D manifolds. We will assume that such a 1D manifold is either a real line $\mathbb{R}$ or a circle $S^1\cong\mathbb{R}/\mathbb{Z}$. That gives $2\times 2= 4$ possibilities, which are useful to compare, in order to convey the idea behind a compactified boson. Note the following observations:


*

*Cases where the target space $M=\mathbb{R}/2\pi R\mathbb{Z}$ is a circle. Then we can replace the circle $M$ with the real line $\mathbb{R}$, if we let the map $\phi$ become multi-valued $x\mapsto [\phi_i(x)]_{i\in\mathbb{Z}}$, where two branches differ$$\phi_i(x)-\phi_j(x)~\in~ 2\pi R\mathbb{Z}$$ by a multiple of $2\pi R$. (The notion of branches makes sense since the map is assumed to be continuous.)

*Cases where the world-space $\Sigma=\mathbb{R}/L\mathbb{Z}$ is a circle. Then we can replace the circle $\Sigma$ with the real line $\mathbb{R}$, if we impose that the map should be $L$-periodic. This means
$$ \phi(x)~=~\phi(x+L) \quad\text{for}\quad  M~=~\mathbb{R},\tag{1} $$
and
$$ [\phi_i(x)]~=~[\phi_j(x+L)] \quad\text{for}\quad  M~=~\mathbb{R}/2\pi R\mathbb{Z}.\tag{2} $$

*In the remainder of this answer, let the target space $M=\mathbb{R}/2\pi R\mathbb{Z}$ be compact, so that the map is multi-valued. (i) In the case without $L$-periodicity, we can just pick one branch $x\mapsto \phi_i(x)$, and work in that "picture". The different branches don't talk to each other, so to speak. (ii) In the case with $L$-periodicity, the periodicity condition (2) may refer to different branches. If we unpack (2), it may become
$$\phi_i(x)-\phi_i(x+L)~=~2\pi R m, $$
where $m\in\mathbb{Z}$ is called the winding number. Interestingly, the winding number $m$ does not depend on which branch (or "picture") $i\in\mathbb{Z}$, we use.
