Introduce penalty for weak (=unsupported) pawns.

We add a penalty for each pawn which is not protected by another pawn
of the same color.
I guess the compiler already does that for you. You can check assembly if
interested.


On Mon, Jun 16, 2014 at 8:01 PM, Jinghao Yan <notifications@github.com>
wrote:

> In src/pawns.cpp:
>
> >
> > -        // Flag the pawn as passed, isolated, doubled or
> > -        // connected (but not the backward one).
> > -        connected =   ourPawns   & adjacent_files_bb(f) & b;
> > -        isolated  = !(ourPawns   & adjacent_files_bb(f));
> > -        doubled   =   ourPawns   & forward_bb(Us, s);
> > -        opposed   =   theirPawns & forward_bb(Us, s);
> > -        passed    = !(theirPawns & passed_pawn_mask(Us, s));
> > +        // Flag the pawn as passed, isolated, doubled,
> > +        // unsupported or connected (but not the backward one).
> > +        connected   =   ourPawns   & adjacent_files_bb(f) & b;
>
> Does it make sense to pull adjacent_files_bb(f) into its own variable
> (since it is used three times at least), as you did for rank_bb(s -
> pawn_push(Us))?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/mcostalba/Stockfish/pull/183/files#r13820395>.
>